Add image perspective editing and related tools
- Implemented the Image Perspective tool for editing image corners in Blender. - Created a new operator `EditImagePerspective` to handle the perspective transformation. - Added a preview feature for the perspective adjustment. - Introduced the `ImagePolylineTool` for editing image masks with polylines. - Developed backend support for Real-ESRGAN model inference, including ONNX integration. - Added functionality for image masking and background removal. - Created unit tests for the Real-ESRGAN ONNX model to ensure correct preprocessing and inference.
This commit is contained in:
@@ -22,11 +22,11 @@ class ModelFile:
|
||||
size: int
|
||||
sha256: str
|
||||
sources: tuple[str, ...]
|
||||
filename: str = "model.onnx"
|
||||
|
||||
@property
|
||||
def destination(self):
|
||||
filename = "model_fp16.onnx" if self.folder.endswith("/onnx") else "model.onnx"
|
||||
return MODELS_DIR / self.folder / filename
|
||||
return MODELS_DIR / self.folder / self.filename
|
||||
|
||||
|
||||
def hf_url(repository, filename):
|
||||
@@ -58,6 +58,23 @@ MODEL_FILES = (
|
||||
hf_url("onnx-community/BEN2-ONNX", "onnx/model_fp16.onnx"),
|
||||
r2_url("BEN2-ONNX", "onnx/model_fp16.onnx"),
|
||||
),
|
||||
"model_fp16.onnx",
|
||||
),
|
||||
ModelFile(
|
||||
"realesr-general-x4v3",
|
||||
4866396,
|
||||
"924ebad6532777303582d4ce7811849b88869231a3ae7093e0f21200249df8d5",
|
||||
(
|
||||
hf_url(
|
||||
"jonathanst29/tinier-upscale-models",
|
||||
"realesr-general-x4v3.onnx",
|
||||
),
|
||||
r2_url(
|
||||
"realesr-general-x4v3",
|
||||
"realesr-general-x4v3.onnx",
|
||||
),
|
||||
),
|
||||
"realesr-general-x4v3.onnx",
|
||||
),
|
||||
ModelFile(
|
||||
"moge-2-vits-normal-onnx",
|
||||
|
||||
Reference in New Issue
Block a user