Taeu / Style-Your-Hair

Official Pytorch implementation of "Style Your Hair: Latent Optimization for Pose-Invariant Hairstyle Transfer via Local-Style-Aware Hair Alignment (ECCV 2022)"
302 stars 42 forks source link

Possible to run on CPU device? #1

Closed spacerunner8 closed 2 years ago

spacerunner8 commented 2 years ago

Hello

Thank you for sharing, the results seem very promising.

I ran the code on my CPU device unfortunately it does not work even I set --device = "cpu". I found out it is because it relies on fused_bias_act.cpp and fused_bias_act_kernel.cu and they rely on CUDA.

In this case, do you think we can only use CPU to generate results?

myoons commented 2 years ago

@spacerunner8 The problem is fixed now. Can you try again with the latest code? (Reflecting the newest commit, https://github.com/Taeu/Style-Your-Hair/pull/2#issue-1319847083)

I tested the code with my Macbook M1 Pro which PyTorch doesn't support GPU.

myoons commented 2 years ago

Issue closed. 😄 Thanks for having interests.

ArsalanAli915 commented 1 year ago

@myoons @Taeu could u please specify the inference time that model has taken. Becouse it takes around 18 mins to inference on GPU T4 google colab. Can I cut the time short. Please help me know.