Open vitasha10 opened 4 months ago
Also errors without web, my script:
from face2face import Face2Face
try:
f2f = Face2Face()
swapped_img = f2f.swap_one(cv2.imread("src.jpg"), cv2.imread("target.jpg"))
except Exception as inst:
print(type(inst))
print(inst.args)
print(inst)
Images in this folder with this names. output:
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: /home/vasya/face2face/face2face/models/insightface./checkpoints/models/buffalo_l/1k3d68.onnx landmark_3d_68 ['None', 3, 192, 192] 0.0 1.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: /home/vasya/face2face/face2face/models/insightface./checkpoints/models/buffalo_l/2d106det.onnx landmark_2d_106 ['None', 3, 192, 192] 0.0 1.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: /home/vasya/face2face/face2face/models/insightface./checkpoints/models/buffalo_l/det_10g.onnx detection [1, 3, '?', '?'] 127.5 128.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: /home/vasya/face2face/face2face/models/insightface./checkpoints/models/buffalo_l/genderage.onnx genderage ['None', 3, 96, 96] 0.0 1.0
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
find model: /home/vasya/face2face/face2face/models/insightface./checkpoints/models/buffalo_l/w600k_r50.onnx recognition ['None', 3, 112, 112] 127.5 127.5
set det-size: (320, 320)
Applied providers: ['CPUExecutionProvider'], with options: {'CPUExecutionProvider': {}}
Killed
Hi vitasha, thank you for raising the issues:
I currently work with
Definitely would help to set it up in an test environment with older python version.
For ONNX runtime. It's stuck to that old version, because the roop version of insightface is a little bit old. Probably it is possible to update the ONNX version and convert the models in a way that they are compatible with the new version.
My system:
On my system it works with both GPUs and also on CPU.
I've created a branch for compatibility issues related tasks. Do you think you could look into something?
I think Docker support would fit into another issue ;) - especially if it should work together with FastTaskAPI.
For now, if you want plain FastAPI you can simply replace all @task_endpoint with standard fastapi routes and kick FastTaskAPI out. Should work fine. I'm still working on the FastSDK to make a smooth client - server interaction / SDK.
Kind regards
I found and solved the dependency problem. It was not in face2face but in the dependency fast-task-API which needed to be updated to the newer media-toolkit version. I've updated fast-task-API and built a new wheel for it.
I've pushed the changes. And built the package. Please try a clean reinstall.
Next step: ONNX update. I'll work on that on compatibility_issue branch.
Let me know if your problem was solved
Now it's working but when someone install from "git+htt..." application also want you (inside some code) to install package from apt. So now it's dublicate, but swap work in test dir.
Please define in README.md that "Killed" msg in console is when RAM ended, I spended two days. It want about 5gb ram to swap photo with CPU. and about 7seconds after loading, 11 with loading everything, 20+ for first time.
I tried to install on fresh server and get this. It want media_toolkit, but there is one.
Also you have in
this mistake
Not "tookit", "toolkit", you forget "l" letter.
This package don't help: