Spaces:
Runtime error
Runtime error
init
Browse files111 unmodified lines11211311411511611711811912088 unmodified lines209210211212213214215216111 unmodified linesdef get_depth_pipeline():feature_extractor = AutoImageProcessor.from_pretrained("LiheYoung/depth-anything-large-hf",torch_dtype=dtype)depth_estimator = AutoModelForDepthEstimation.from_pretrained("LiheYoung/depth-anything-large-hf",torch_dtype=dtype)return feature_extractor, depth_estimator88 unmodified linesself.seg_image_processor, self.image_segmentor = get_segmentation_pipeline()self.depth_feature_extractor, self.depth_estimator = get_depth_pipeline()self.depth_estimator = self.depth_estimator.to(device)@spaces.GPUdef generate_design(self, empty_room_image: Image, prompt: str, guidance_scale: int = 10, num_steps: int = 50, strength: float =0.9, img_size: int = 640) -> Image:"""111 unmodified lines11211311411511611711811912088 unmodified lines209210211212213214215111 unmodified linesdef get_depth_pipeline():feature_extractor = AutoImageProcessor.from_pretrained("LiheYoung/depth-anything-large-hf",torch_dtype=dtype).to(device)depth_estimator = AutoModelForDepthEstimation.from_pretrained("LiheYoung/depth-anything-large-hf",torch_dtype=dtype).to(device)return feature_extractor, depth_estimator88 unmodified linesself.seg_image_processor, self.image_segmentor = get_segmentation_pipeline()self.depth_feature_extractor, self.depth_estimator = get_depth_pipeline()@spaces.GPUdef generate_design(self, empty_room_image: Image, prompt: str, guidance_scale: int = 10, num_steps: int = 50, strength: float =0.9, img_size: int = 640) -> Image:"""
app.py+3-4