flux-lora-the-explorer / depth_estimator.py
John6666's picture
Upload 49 files
f1d6334 verified
raw
history blame contribute delete
348 Bytes
import numpy as np
import PIL.Image
from controlnet_aux.util import HWC3
from transformers import pipeline
from cv_utils import resize_image
class DepthEstimator:
def __init__(self):
self.model = pipeline("depth-estimation")
def __call__(self, image: np.ndarray, **kwargs) -> PIL.Image.Image:
return image