Giter VIP home page Giter VIP logo

lastdefiance20 / tryyours-virtual-try-on Goto Github PK

View Code? Open in Web Editor NEW
92.0 1.0 35.0 22.21 MB

Virtual Try On site using HR-VITON. Anyone can try it using their own Image with clothes image.

Jupyter Notebook 0.47% Python 94.29% Shell 0.36% C++ 1.92% Cuda 2.73% Dockerfile 0.08% Makefile 0.02% CMake 0.01% JavaScript 0.03% CSS 0.04% HTML 0.07%
detectron2 graphonomy posenet virtual-try-on virtual-tryon-ecommerce hr-viton gans

tryyours-virtual-try-on's Introduction

TryYours - High Resolution Virtual Try On site using HR-VITON.

teaser image

KR presentation

Colab Demo

You can simply try it using colab Open In Colab

Team member

Jaeyoon Jung, soongsil university Seungwoo Han, soongsil university

Process Overview

process overview image

Code Running Environment

run at ubuntu

use docker image of paperspace gradient Scratch docker
https://hub.docker.com/r/paperspace/gradient-base
docker tag
pt112-tf29-jax0314-py39-20220803

Installation

see INSTALL.md for the installation we will add INSTALL.md soon.

References

HR-VITON

https://github.com/sangyun884/HR-VITON

Posenet

https://github.com/rwightman/posenet-python

Graphonomy

https://github.com/Gaoyiminggithub/Graphonomy

detectron2

https://github.com/facebookresearch/detectron2

cloth image segmentation

https://github.com/ternaus/cloths_segmentation

tryyours-virtual-try-on's People

Contributors

lastdefiance20 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

Watchers

 avatar

tryyours-virtual-try-on's Issues

Noise In the Output

image
image

Hi @lastdefiance20 there seems to be lot of noise in the output and full sleeves and even sleeveless t-shirts often gets their sleeves short? what could be the issue? Is it that dependencies may be the problems. Why is it giving half sleeves all the time?
Is there any parameter which i can tweak to get better results?
Though this is the issue while running locally.

Getting error

getting the following error please help me out

C:\Users\mhash\Downloads\TryYours-Virtual-Try-On-main2\TryYours-Virtual-Try-On-main>python main.py
Get mask of cloth

Get openpose coordinate using posenet

Traceback (most recent call last):
File "C:\Users\mhash\Downloads\TryYours-Virtual-Try-On-main2\TryYours-Virtual-Try-On-main\posenet.py", line 10, in
net = net.cuda()
^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 915, in cuda
return self._apply(lambda t: t.cuda(device))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 779, in _apply
module._apply(fn)
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 779, in _apply
module._apply(fn)
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 779, in _apply
module._apply(fn)
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 804, in _apply
param_applied = fn(param)
^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\nn\modules\module.py", line 915, in
return self.apply(lambda t: t.cuda(device))
^^^^^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\cuda_init
.py", line 284, in _lazy_init
raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled
Generate semantic segmentation using Graphonomy-Master library

Constructing DeepLabv3+ model...
Number of classes: 20
Output stride: 16
Number of Input Channels: 3
Traceback (most recent call last):
File "C:\Users\mhash\Downloads\TryYours-Virtual-Try-On-main2\TryYours-Virtual-Try-On-main\Graphonomy-master\exp\inference\inference.py", line 191, in
x = torch.load(opts.loadmodel)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\serialization.py", line 997, in load
with _open_file_like(f, 'rb') as opened_file:
^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\serialization.py", line 444, in _open_file_like
return open_file(name_or_buffer, mode)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\mhash\anaconda3\Lib\site-packages\torch\serialization.py", line 425, in init
super().init(open(name, mode))
^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: './inference.pth'
[ WARN:[email protected]] global loadsave.cpp:248 cv::findDecoder imread
('./resized_segmentation_img.png'): can't open/read file: check file path/integrity
Traceback (most recent call last):
File "C:\Users\mhash\Downloads\TryYours-Virtual-Try-On-main2\TryYours-Virtual-Try-On-main\main.py", line 44, in
mask_img=cv2.resize(mask_img,(768,1024))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
cv2.error: OpenCV(4.9.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:4152: error: (-215:Assertion failed) !ssize.empty() in function 'cv::resize'

run problem

On which tool have you used it, did you do it on Google Colab or in Ubuntu.
Give all the steps to run it

What did the training data look like?

Can you please tell what did the training data images consist of like what all images you fed into training i want to train it for different dataset of images for my project .Please Help πŸ™

demo UI

Hi,
This is amazing!!.. Its working superb with different images i tried. Now, Can i get any guidance on how can i make a demo UI such as gradio application or streamlit application with this on VS code. Or what essential changes will i have to make in the code files for it?

data.json is miss?

Hi,in get_densepose.py, it needs a data.json file. I can't find it or how can I generate it?

Noise in the output

This is my input.
Screenshot 2024-04-24 171420

I got output like this.
Screenshot 2024-04-24 171435

Can anyone tell what should I change in my code ?

where is the inference.pth?

image

Hi bro! In the part of Generate semantic segmentation using Graphonomy-Master library of "main.py", there is a model path named inference.pth, but i don't know how to get it or generate it, would you please tell me some infomations about it? thanks

Not able to generate data.json and segmentation fault while running application

I tried using the repo with changes in detectron2 and main.py suggested in issue@
And still getting the following error:

Get mask of cloth

Get openpose coordinate using posenet

Segmentation fault
Generate semantic segmentation using Graphonomy-Master library

Constructing DeepLabv3+ model...
Number of classes: 20
Output stride: 16
Number of Input Channels: 3
load model: ./inference.pth
Segmentation fault

Generate Densepose image using detectron2 library

[05/23 07:54:23 apply_net]: Loading config from detectron2/projects/DensePose/configs/densepose_rcnn_R_50_FPN_s1x.yaml
[05/23 07:54:23 apply_net]: Loading model from https://dl.fbaipublicfiles.com/densepose/densepose_rcnn_R_50_FPN_s1x/165712039/model_final_162be9.pkl
[05/23 07:54:25 apply_net]: Loading data from origin.jpg
Segmentation fault
Traceback (most recent call last):
File "/home/deepk/Desktop/backend/virtual_tryon/TryYours-Virtual-Try-On/get_densepose.py", line 27, in
with open('./data.json', 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: './data.json'

Run HR-VITON to generate final image

Start to test! - HR-VITON
Network [SPADEGenerator] was created. Total number of parameters: 100.5 million. To see the architecture, do print(network).
Segmentation fault

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.