Giter Club home page Giter Club logo

virtual_try_on_use_deep_learning's Introduction

virtual_try_on_use_deep_learning

使用深度学习算法实现虚拟试衣,结合了人体姿态估计、人体分割、几何匹配和GAN,四种模型。仅仅只依赖opencv库就能运行

这套程序实现起来挺复杂的,因为它里面包含了4种深度学习模型,而且有一个自定义层CorrelationLayer,需要自己编程实现它。 然而我想使用onnxruntime作为推理引擎时,onnxruntime不支持自定义层的,这算是opencv的一个优势的。

本套程序的主程序文件是 main.py,模型文件从百度云盘下载, 链接:https://pan.baidu.com/s/13Eic0aiMtCGY7iigjg71DQ 提取码:xsl5

这套程序只有Python版本的,我在本地编写了C++程序,但是输出结果跟Python版本的输出结果始终不一致, 对于这个bug我还没有找到原因,因此我在github只发布python程序的。程序启动运行之后,要等几秒种后才能弹窗显示结果, 程序运行速度慢的问题还有待优化。

virtual_try_on_use_deep_learning's People

Contributors

hpc203 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

virtual_try_on_use_deep_learning's Issues

模型文件不存在

5个模型文件 四个在PYCHARM 里标志是问号,且程序跑起来说模型文件不存在。求问该怎么办

下载模型文件后运行报错,希望作者看到后能帮处理一下。谢谢

首先从项目描述上看,作者能力应当很强,项目功能也很吸引人,所以尝试执行。

但下载模型后运行时,发现会报下列错误:

[ERROR:[email protected]] global /Users/xperience/actions-runner/_work/opencv-python/opencv-python/opencv/modules/dnn/src/dnn.cpp (3875) getLayerShapesRecursively OPENCV/DNN: [Permute]:(Mean/nhwc): getMemoryShapes() throws exception. inputs=1 outputs=0/1 blobs=0
[ERROR:[email protected]] global /Users/xperience/actions-runner/_work/opencv-python/opencv-python/opencv/modules/dnn/src/dnn.cpp (3878) getLayerShapesRecursively input[0] = [ 1 2 20 384 384 ]
[ERROR:[email protected]] global /Users/xperience/actions-runner/_work/opencv-python/opencv-python/opencv/modules/dnn/src/dnn.cpp (3888) getLayerShapesRecursively Exception message: OpenCV(4.5.5) /Users/xperience/actions-runner/_work/opencv-python/opencv-python/opencv/modules/dnn/src/layers/permute_layer.cpp:140: error: (-215:Assertion failed) (int)_numAxes == inputs[0].size() in function 'getMemoryShapes'

定位到 报错 出现在human_parsing.py文件的run_net()下
net.forward()这句。
猜测问题可能出在 lip_jppnet_384.pb 上,路径用的是绝对路径?

因为对onnx这些完全不熟悉,只能希望作者看到后,有空处理一下。

谢谢。

Google drive link

Can you provide Google drive link or any other means to download pretrained model? Thanks

cv2.error

cv2.error: OpenCV(4.6.0) D:\a\opencv-python\opencv-python\opencv\modules\dnn\src\layers\permute_layer.cpp:161: error: (-215:Assertion failed) (int)_numAxes == inputs[0].size() in function 'cv::dnn::PermuteLayerImpl::getMemoryShapes'

ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (12,) + inhomogeneous part.

File "C:/Project/PycharmProject/virtual_try_on_use_deep_learning/main.py", line 79, in _precompute_coeffs
points = np.array([np.arange(row) + xmins[i] for i, row in enumerate(bounds[1::2])]) / filterscale
ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (12,) + inhomogeneous part.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.