PhotoMaker icon indicating copy to clipboard operation
PhotoMaker copied to clipboard

Howto: Windows Installation

Open bmaltais opened this issue 1 year ago • 19 comments

For windows users out there, I have created a fork with an easy set of instructions and updates to facilitate the use on windows. You can find the 1st release at:

https://github.com/bmaltais/PhotoMaker

This fork also support non square output format so you can produre results like:

image

You will find the width and height setting under the Advanced Accordion in the GUI:

image

Once you have followed the installation instructions you simply start the Gradio GUI with: .\gui.bat

bmaltais avatar Jan 17 '24 12:01 bmaltais

The following message appears when installing according to the instructions
QQ截图20240117205420

xhoxye avatar Jan 17 '24 12:01 xhoxye

按说明安装出现以下信息 QQ截图20240117205420

另外如果使用python_embeded的可以安装吗?

My solution require a local installation of python 3.10.9... I don't think it will run properly with another type of python installation... sorry ;-(

bmaltais avatar Jan 17 '24 12:01 bmaltais

I've forced the install torch==2.0.1 torchvision==0.15.2 Now that I'm stuck in the place where I downloaded the model, where do I store the model I downloaded from huggingface? QQ截图20240117210728

QQ截图20240117213039

xhoxye avatar Jan 17 '24 13:01 xhoxye

Very cool! Thank you @bmaltais. We have listed your contributions in README file.

Paper99 avatar Jan 17 '24 13:01 Paper99

Very cool! Thank you @bmaltais. We have listed your contributions in README file.很

Do you consider the situation of download interruptions?

xhoxye avatar Jan 17 '24 14:01 xhoxye

QQ截图20240117221106 The download is complete and a new issue has appeared

xhoxye avatar Jan 17 '24 14:01 xhoxye

@xhoxye Look like you still have some network download issue... causing the timeout...

bmaltais avatar Jan 17 '24 14:01 bmaltais

QQ截图20240117224024

The download seems to be complete, and it shows a timeout when it loads

xhoxye avatar Jan 17 '24 14:01 xhoxye

QQ截图20240117224024

The download seems to be complete, and it shows a timeout when it loads

Humm... this is something happening with the app.py code at this point. I wish I could help you out more but this is outside facilitating the installation and calling the app.py

Keep in mind... running gradio python app is not a walk in the park... there are many things that can go wrong as config on individual system can have a significant impact.

bmaltais avatar Jan 17 '24 14:01 bmaltais

Any ideas about this problem? image

Woody3097 avatar Jan 17 '24 15:01 Woody3097

I modified the model path and finally got into the UI, but it was very slow and the GPU didn't seem to be being used? Still no, come back tomorrow QQ截图20240117234603 QQ截图20240117234556 QQ截图20240117234349 QQ截图20240117234327 QQ截图20240117233455

xhoxye avatar Jan 17 '24 15:01 xhoxye

QQ截图20240117224024

The download seems to be complete, and it shows a timeout when it loads

same problem. First, it loads the models for about 10 minutes, after which it starts. But photo generation doesn’t work, it loads endlessly. The video card is not loaded at all. изображение

slavidich avatar Jan 17 '24 16:01 slavidich

Any ideas about this problem? image

This is odd... maybe I need to add some other pre-requirements like Visual Studio... I do have it installed on my computer... it is possible that it is required to build photomaker... strange... I will have to do some investigation

bmaltais avatar Jan 17 '24 17:01 bmaltais

I found out that you cant install binsandbytes with cuda support on windows ..so it will not use GPU but only CPU... so what now ?

Edit: What is this ? https://github.com/Keith-Hon/bitsandbytes-windows

getmad4love avatar Jan 17 '24 20:01 getmad4love

Any ideas about this problem? image

This is odd... maybe I need to add some other pre-requirements like Visual Studio... I do have it installed on my computer... it is possible that it is required to build photomaker... strange... I will have to do some investigation

I deleted the last dot in the requirements-windows.txt file, and now everything works

Woody3097 avatar Jan 17 '24 20:01 Woody3097

Any ideas about this problem? image

This is odd... maybe I need to add some other pre-requirements like Visual Studio... I do have it installed on my computer... it is possible that it is required to build photomaker... strange... I will have to do some investigation

I deleted the last dot in the requirements-windows.txt file, and now everything works

Really strange. I deleted the venv, removed the wheel part, re-installed and it work fine...

Can you try to do a git pull in the terminal to check if you have the latest code?

bmaltais avatar Jan 17 '24 20:01 bmaltais

I found out that you cant install binsandbytes with cuda support on windows ..so it will not use GPU but only CPU... so what now ?

Edit: What is this ? https://github.com/Keith-Hon/bitsandbytes-windows

I managed to get PhotoMaker to work yesterday, i used https://github.com/jllllll/bitsandbytes-windows-webui/releases pip uninstall bitsandbytes pip uninstall bitsandbytes-windows pip install https://github.com/jllllll/bitsandbytes-windows-webui/releases/download/wheels/bitsandbytes-0.41.1-py3-none-win_amd64.whl

ohmygoobness avatar Jan 17 '24 21:01 ohmygoobness

How does anaconda access gui.bat

monkeycc avatar Jan 18 '24 09:01 monkeycc

Good question. Installing python 3.10.9 directly from python is the supported method for the underlying so-script from Koby’s. Might work with anaconda but I have not tested it.

bmaltais avatar Jan 18 '24 10:01 bmaltais