fixed issue 13

This commit is contained in:
David Chatel
2024-06-20 14:57:56 +02:00
parent b22ec319cb
commit fd64202ad9
2 changed files with 3 additions and 3 deletions
+1
View File
@@ -5,6 +5,7 @@ These custom nodes provide a rotation aware face extraction, paste back, and var
![Comparison](examples/comparison.jpg)
## Patch notes
- 2024-06-20 - fixed issue [13](https://github.com/dchatel/comfyui_facetools/issues/13)
- 2024-06-14 - Sent yolo to cuda device if available (credits: kilroythethird, thanks for the suggestion!)
- 2024-06-14 - Dropped the requirement from insightface completely.
- 2024-05-22 - Updated GenderFaceFilter node.
+2 -3
View File
@@ -8,11 +8,10 @@ from scipy.spatial import ConvexHull
from folder_paths import models_dir
from .BiSeNet import BiSeNet
from ultralytics import YOLO
from onnxruntime import InferenceSession
from onnxruntime import InferenceSession, get_available_providers
from transformers import SegformerImageProcessor, SegformerForSemanticSegmentation
from skimage import transform as trans
arcface_dst = np.array(
[[38.2946, 51.6963], [73.5318, 51.5014], [56.0252, 71.7366],
[41.5493, 92.3655], [70.7299, 92.2041]],
@@ -63,7 +62,7 @@ class Models:
@classmethod
def lmk(cls, crop):
if '_lmk' not in cls.__dict__:
cls._lmk = InferenceSession(os.path.join(models_dir, 'landmarks', 'fan2_68_landmark.onnx'))
cls._lmk = InferenceSession(os.path.join(models_dir, 'landmarks', 'fan2_68_landmark.onnx'), providers=get_available_providers())
lmk = cls._lmk.run(None, {'input': crop})[0]
return lmk