HandEdit-LoRA / README.md
HandEdit's picture
Add files using upload-large-folder tool
ce47bc4 verified
|
Raw History Blame
3.3 kB
---
library_name: peft
tags:
- image-editing
- lora
- robotics
- hand-editing
base_model:
- meituan-longcat/LongCat-Image-Edit
- Shitao/OmniGen-v1
- black-forest-labs/FLUX.2-klein-base-4B
- stepfun-ai/Step1X-Edit
---
# HandEdit LoRA
HandEdit provides parameter-efficient LoRA adapters that specialize four
open-source image-editing backbones for human-to-robot-hand replacement.
We build more than 20K aligned training pairs from the HandEdit data. Each pair
contains an input image with a real human hand interacting with an object and a
corresponding target image in which only the hand is replaced by an Inspire
robotic hand. The training instruction asks the model to preserve the original
wrist pose, finger configuration, grasp relation, object contact points,
interaction object, background, lighting, and camera viewpoint as closely as
possible.
Only LoRA parameters are released; the full base-model weights are not
redistributed.
## Models
| Adapter | Official base model | Local checkpoint |
| --- | --- | --- |
| LongCat-Image-Edit | [`meituan-longcat/LongCat-Image-Edit`](https://huggingface.co/meituan-longcat/LongCat-Image-Edit) | `checkpoints/longcat/` |
| OmniGen-v1 | [`Shitao/OmniGen-v1`](https://huggingface.co/Shitao/OmniGen-v1) | `checkpoints/omnigen/` |
| FLUX.2 Klein Base 4B | [`black-forest-labs/FLUX.2-klein-base-4B`](https://huggingface.co/black-forest-labs/FLUX.2-klein-base-4B) | `checkpoints/flux2/handedit_flux2_klein4b_lora.safetensors` |
| Step1X-Edit | [`stepfun-ai/Step1X-Edit`](https://huggingface.co/stepfun-ai/Step1X-Edit) | `checkpoints/step1x/inspire_step1x_r32_a16_res512.safetensors` |
## Download
**[Download all four sanitized LoRA checkpoints](https://huggingface.co/HandEdit/HandEdit-LoRA/resolve/main/checkpoints.zip?download=true)**
Or download and verify them from the command line:
```bash
pip install huggingface_hub
python scripts/download_weights.py
python scripts/verify_weights.py
```
The published ZIP and individual adapter files are hosted in
[`HandEdit/HandEdit-LoRA`](https://huggingface.co/HandEdit/HandEdit-LoRA).
## Inference
Detailed environment setup and commands are in
[`docs/INFERENCE.md`](docs/INFERENCE.md). The shortest examples are:
```bash
# LongCat-Image-Edit
python scripts/infer_longcat_lora.py \
--input_dir ./examples/input --output_dir ./outputs/longcat
# OmniGen-v1
python scripts/infer_omnigen_lora.py \
--input_dir ./examples/input --output_dir ./outputs/omnigen
# FLUX.2 Klein Base 4B
python scripts/infer_flux2_lora.py \
--input_dir ./examples/input --output_dir ./outputs/flux2
# Step1X-Edit
python scripts/infer_step1x_lora.py \
--repo_dir ./third_party/Step1X-Edit \
--model_dir ./weights/Step1X-Edit \
--input_dir ./examples/input --output_dir ./outputs/step1x \
--quantized --offload
```
## Release hygiene
The public weights are sanitized copies. Training-data identifiers, dataset
sizes, local paths, author fields, timestamps, session information, and other
training-process metadata were removed without changing tensor bytes. See
[`SANITIZATION.md`](SANITIZATION.md) and `weights_manifest.json`.
## Base-model licenses
Users must follow the license and access terms of each official base model.
This repository does not redistribute the four base models.