Skip to content

script issue or miss version incompatibility  #2898

Description

@sliverfish69

im using CMD with python3.10.11 running script
inswapper_128.onnx
Onnxruntime=1.16.2
Numpy=1.26.2
Insightface=0.7.3

___This is the error nomatter how i write the script __

C:\LocalProject\FaceLifts>python run_swap.py
Loading AI Swapper engine...
2026-08-28 08:44:18.1637446 [W:onnxruntime:, graph.cc:4885 onnxruntime::Graph::CleanUnusedInitializersAndNodeArgs] Removing initializer 'buff2fs'. It is not used by any node and should be removed from the model.
inswapper-shape: [1, 3, 128, 128]
Initializing local face detector...
C:\Users\6985t\AppData\Local\Programs\Python\Python310\lib\site-packages\onnxruntime\capi\onnxruntime_inference_collection.py:123: UserWarning: Specified provider 'CUDAExecutionProvider' is not in available provider names.Available providers: 'AzureExecutionProvider, CPUExecutionProvider'
warnings.warn(
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
model ignore: C:\Users\6985t/.insightface\models\buffalo_l\1k3d68.onnx landmark_3d_68
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: C:\Users\6985t/.insightface\models\buffalo_l\2d106det.onnx landmark_2d_106 ['None', 3, 192, 192] 0.0 1.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: C:\Users\6985t/.insightface\models\buffalo_l\det_10g.onnx detection [1, 3, '?', '?'] 127.5 128.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
model ignore: C:\Users\6985t/.insightface\models\buffalo_l\genderage.onnx genderage
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
inswapper-shape: [1, 3, 128, 128]
Traceback (most recent call last):
File "C:\LocalProject\FaceLifts\run_swap.py", line 58, in
main()
File "C:\LocalProject\FaceLifts\run_swap.py", line 20, in main
app = insightface.app.FaceAnalysis(name='buffalo_l', allowed_modules=['detection', 'landmark_2d_106'])
File "C:\Users\6985t\AppData\Local\Programs\Python\Python310\lib\site-packages\insightface\app\face_analysis.py", line 52, in init
elif allowed_modules is not None and model.taskname not in allowed_modules:
AttributeError: 'INSwapper' object has no attribute 'taskname'

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions