Original repository: WiLoR, thanks to the authors for sharing
I have simplified WiLoR, focusing on the inference process. Now it can be installed via pip and used directly, and it will automatically download the model.
Note: make sure you are using Python3.10
- install:
pip install git+https://github.com/warmshao/WiLoR-mini - Usage:
import torch import cv2 from wilor_mini.pipelines.wilor_hand_pose3d_estimation_pipeline import WiLorHandPose3dEstimationPipeline device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu") dtype = torch.float16 pipe = WiLorHandPose3dEstimationPipeline(device=device, dtype=dtype) img_path = "assets/img.png" image = cv2.imread(img_path) image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB) outputs = pipe.predict(image)
For more usage examples, please refer to: tests/test_pipelines.py