fix(docker): use HuggingFace mirror for colorization caffemodel

The original Berkeley server (eecs.berkeley.edu) is dead, returning
404 after redirect. Switched to a reliable HuggingFace-hosted mirror
of the same 129MB model file.
This commit is contained in:
stirling-image
2026-04-14 17:41:39 +08:00
parent fce2c64ba2
commit 382e974eed
+1 -1
View File
@@ -89,7 +89,7 @@ FACEXLIB_PARSE_MIN_SIZE = 80_000_000 # ~85 MB
OPENCV_COLORIZE_DIR = "/opt/models/colorize-opencv"
OPENCV_PROTO_URL = "https://raw.githubusercontent.com/richzhang/colorization/caffe/colorization/models/colorization_deploy_v2.prototxt"
OPENCV_PROTO_PATH = os.path.join(OPENCV_COLORIZE_DIR, "colorization_deploy_v2.prototxt")
OPENCV_CAFFE_URL = "http://eecs.berkeley.edu/~rich.zhang/projects/2016_colorization/files/demo_v2/colorization_release_v2.caffemodel"
OPENCV_CAFFE_URL = "https://huggingface.co/spaces/BilalSardar/Black-N-White-To-Color/resolve/main/colorization_release_v2.caffemodel"
OPENCV_CAFFE_PATH = os.path.join(OPENCV_COLORIZE_DIR, "colorization_release_v2.caffemodel")
OPENCV_CAFFE_MIN_SIZE = 100_000_000 # ~129 MB
OPENCV_POINTS_URL = "https://raw.githubusercontent.com/richzhang/colorization/caffe/colorization/resources/pts_in_hull.npy"