From f25355dd619b52266ac7f9b500fa587d6b17a9fe Mon Sep 17 00:00:00 2001 From: iyume Date: Mon, 26 Feb 2024 00:05:17 +0800 Subject: [PATCH] remove unused dependency --- openpose/annotator/openpose/__init__.py | 5 +---- openpose/run_openpose.py | 19 ------------------- requirements.txt | 1 - 3 files changed, 1 insertion(+), 24 deletions(-) diff --git a/openpose/annotator/openpose/__init__.py b/openpose/annotator/openpose/__init__.py index cf6a81d..5d4e4aa 100644 --- a/openpose/annotator/openpose/__init__.py +++ b/openpose/annotator/openpose/__init__.py @@ -5,7 +5,6 @@ # 4th Edited by ControlNet (added face and correct hands) import os -import pdb os.environ["KMP_DUPLICATE_LIB_OK"] = "TRUE" @@ -13,9 +12,7 @@ import torch import numpy as np from . import util from .body import Body -from .hand import Hand -from .face import Face -from annotator.util import annotator_ckpts_path +from ..util import annotator_ckpts_path body_model_path = "https://huggingface.co/lllyasviel/Annotators/resolve/main/body_pose_model.pth" hand_model_path = "https://huggingface.co/lllyasviel/Annotators/resolve/main/hand_pose_model.pth" diff --git a/openpose/run_openpose.py b/openpose/run_openpose.py index 7aad35b..91bf135 100644 --- a/openpose/run_openpose.py +++ b/openpose/run_openpose.py @@ -1,30 +1,11 @@ -import pdb - -import config -from pathlib import Path -import sys - -PROJECT_ROOT = Path(__file__).absolute().parents[0].absolute() -sys.path.insert(0, str(PROJECT_ROOT)) -import os - -import cv2 -import einops import numpy as np -import random -import time -import json # from pytorch_lightning import seed_everything from .annotator.util import resize_image, HWC3 from .annotator.openpose import OpenposeDetector -import argparse from PIL import Image import torch -import pdb - -# os.environ['CUDA_VISIBLE_DEVICES'] = '0,1,2,3' class OpenPose: def __init__(self): diff --git a/requirements.txt b/requirements.txt index d2b4540..f6cb1ce 100644 --- a/requirements.txt +++ b/requirements.txt @@ -12,6 +12,5 @@ accelerate matplotlib tqdm gradio -config einops ninja