mirror of
				https://github.com/qurator-spk/sbb_binarization.git
				synced 2025-10-31 01:24:14 +01:00 
			
		
		
		
	adapt to TF1 deprecation
This commit is contained in:
		
							parent
							
								
									ad50ed287d
								
							
						
					
					
						commit
						416b5dd7e2
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		|  | @ -39,10 +39,10 @@ class SbbBinarizer: | ||||||
|             self.models.append(self.load_model(model_file)) |             self.models.append(self.load_model(model_file)) | ||||||
| 
 | 
 | ||||||
|     def start_new_session(self): |     def start_new_session(self): | ||||||
|         config = tf.ConfigProto() |         config = tf.compat.v1.ConfigProto() | ||||||
|         config.gpu_options.allow_growth = True |         config.gpu_options.allow_growth = True | ||||||
| 
 | 
 | ||||||
|         self.session = tf.Session(config=config)  # tf.InteractiveSession() |         self.session = tf.compat.v1.Session(config=config)  # tf.InteractiveSession() | ||||||
|         tensorflow_backend.set_session(self.session) |         tensorflow_backend.set_session(self.session) | ||||||
| 
 | 
 | ||||||
|     def end_session(self): |     def end_session(self): | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue