зеркало из
				https://github.com/ssciwr/AMMICO.git
				synced 2025-10-30 13:36:04 +02:00 
			
		
		
		
	reduce code smells
Этот коммит содержится в:
		
							родитель
							
								
									0df2322774
								
							
						
					
					
						Коммит
						3cf6794d56
					
				| @ -52,12 +52,8 @@ class ObjectCVLib(ObjectsMethod): | |||||||
|         image_path: The path to the local file. |         image_path: The path to the local file. | ||||||
|         """ |         """ | ||||||
|         img = cv2.imread(image_path) |         img = cv2.imread(image_path) | ||||||
|         # preimg = Image.open(image_path).convert("RGB") |  | ||||||
|         # preimg2 = np.asarray(preimg) |  | ||||||
|         # img = cv2.cvtColor(preimg2, cv2.COLOR_BGR2RGB) |  | ||||||
| 
 | 
 | ||||||
|         _, label, _ = cv.detect_common_objects(img) |         _, label, _ = cv.detect_common_objects(img) | ||||||
|         # output_image = draw_bbox(im, bbox, label, conf) |  | ||||||
|         objects = objects_from_cvlib(label) |         objects = objects_from_cvlib(label) | ||||||
|         return objects |         return objects | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -28,7 +28,6 @@ class SummaryDetector(AnalysisMethod): | |||||||
|         return summary_model, summary_vis_processors |         return summary_model, summary_vis_processors | ||||||
| 
 | 
 | ||||||
|     def load_model(self, model_type): |     def load_model(self, model_type): | ||||||
|         # self.summary_device = device("cuda" if cuda.is_available() else "cpu") |  | ||||||
|         select_model = { |         select_model = { | ||||||
|             "base": SummaryDetector.load_model_base, |             "base": SummaryDetector.load_model_base, | ||||||
|             "large": SummaryDetector.load_model_large, |             "large": SummaryDetector.load_model_large, | ||||||
|  | |||||||
		Загрузка…
	
	
			
			x
			
			
		
	
		Ссылка в новой задаче
	
	Block a user
	 Inga Ulusoy
						Inga Ulusoy