amjltc295 / VITON_realtime

Real-time virtual try-on demo for 2018 Make NTU, Team Liver4Faliure
85 stars 28 forks source link

This application failed to start because it could not find or load the Qt platform plugin "xcb" #1

Closed nvnnghia closed 6 years ago

nvnnghia commented 6 years ago

Thanks for sharing, I run the code and met the following problem python VITON_Demo_post.py /home/phatv/anaconda2/envs/MakeNTU/lib/python3.6/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype fromfloattonp.floatingis deprecated. In future, it will be treated asnp.float64 == np.dtype(float).type`. from ._conv import register_converters as _register_converters [2018-06-11 17:37:47,103] {VITON_Demo_post.py:744} INFO - Welcome to Liver Failure real-time VITON demo! [2018-06-11 17:37:47,103] {VITON_Demo_post.py:745} INFO - Press q to exit. [2018-06-11 17:37:47,109] {VITON_Demo_post.py:703} INFO - Threads started This application failed to start because it could not find or load the Qt platform plugin "xcb" in "".

Available platform plugins are: minimal, offscreen, xcb.

Reinstalling the application may fix this problem. Aborted (core dumped) ` Any suggestion? Thanks

amjltc295 commented 6 years ago

Hi nvnnghia,

I never met this problem before, but it seems to be a Qt5 issue. What platform are you working on? Our system has only been tested on Ubuntu 16.04, and the main app should be run locally (with display). Trying to google the error may help, such as https://stackoverflow.com/questions/17106315/failed-to-load-platform-plugin-xcb-while-launching-qt5-app-on-linux-without

Allen

nvnnghia commented 6 years ago

Thanks, What should I do if I just want to run the program without using Qt5. I just want to simply show the result by opencv.

amjltc295 commented 6 years ago

Fixing the Qt5 problem should be the easiest since the threading module requires it. Still, if you just want to see the result, you could try to load your image as what I have done in the five threads. See the run() function in the five workers in VITON_Demo_post.py and put them in another file without using threading and queues. The threading just helps to make them run parallelly, while the five workers' job could be done one by one as well.

nvnnghia commented 6 years ago

Thank you very much, Now, Qt5 problem is fixed, but I have another problem. When I run it only showed the Input and Clothes window. There is no Pose window, no segmentation window, etc. I used all the provided data from your repo. My environment: Ubuntu 16.04, python2.7. By the way, Why you did not implement the second stage of the original repo?

amjltc295 commented 6 years ago

Did you control it with the keyboard? You need to press 'c' to capture an image. (To make it real-time, a faster segmentation network is needed, while I just have a ResNet101 available.) Please show me the error messages if you fail to control it. The second stage requires TPS transformation, which is written in Matlab, and I couldn't find one to replace it. It will be great if you could translate the code into Python or find a module that could do the similar transformation. We just didn't have that much time (it was a 24-hour Makeathon). By the way, the program is running with Python3.6. environment.yaml would help you install Python3.6 even if you are using annaconda2.

nvnnghia commented 6 years ago

Thank you very much. I will implement the second part in python and update the result later.