GithubHelp home page GithubHelp logo

cuiaiyu / dressing-in-order Goto Github PK

View Code? Open in Web Editor NEW
495.0 495.0 120.0 4.56 MB

(ICCV'21) Official code of "Dressing in Order: Recurrent Person Image Generation for Pose Transfer, Virtual Try-on and Outfit Editing" by Aiyu Cui, Daniel McKee and Svetlana Lazebnik

Home Page: https://cuiaiyu.github.io/dressing-in-order

License: Other

Python 10.31% Jupyter Notebook 87.78% C++ 0.11% Cuda 1.68% Shell 0.12%
fashion gan iccv2021 pose-transfer virtual-try-on

dressing-in-order's People

Contributors

cuiaiyu avatar dependabot[bot] avatar ziyodullodev 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dressing-in-order's Issues

No images are printed:

when i tried to run the pose transfer for DiOr, I got this as the output can anyone help please ?
image
/usr/local/lib/python3.7/dist-packages/torch/nn/functional.py:3635: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details. "See the documentation of nn.Upsample for details.".format(mode) /usr/local/lib/python3.7/dist-packages/torch/nn/functional.py:4004: UserWarning: Default grid_sample and affine_grid behavior has changed to align_corners=False since 1.3.0. Please specify align_corners=True if the old behavior is desired. See the documentation of grid_sample for details. "Default grid_sample and affine_grid behavior has changed " /content/dressing-in-order/utils/pose_utils.py:91: FutureWarning: draw.circle is deprecated in favor of draw.disk.draw.circle will be removed in version 0.19 yy, xx = circle(joint[0], joint[1], radius=radius, shape=img_size) Clipping input data to the valid range for imshow with RGB data ([0..1] for floats or [0..255] for integers). torch.Size([18, 256, 176])

Person doesn't look the same in results TryOn

Hello, thank you again for this great job.
I am trying the google colab project with custom images, but the face don't look the same person, even the person appears with a beard, despite the fact that in the input image he did not have.

  1. I rezise the input image to 750x1101

  2. I generated the 18 keypoints with COCO data set, using this (the input image for open pose was 175x256):
    !cd openpose && ./build/examples/openpose/openpose.bin --image_dir '{colab_image_path}' --model_pose COCO --write_json '{colab_openpose_image_path}' --display 0 --render_pose 0

  3. I generated the parse image using Human_Parsing_shcp

But the results are a little weird, as you can se bellow:
image

The fashion dataset looks good
image

Am I doing something wrog or these results are normal? Thank you

cannot import name 'block_extractor_cuda'

Hi,

This error pops up: ImportError: cannot import name 'block_extractor_cuda'

I do not know that is it because the .cc format or others and what should I do next?

Bad key "text.kerning_factor" on line 4 in
/Midgard/home/sanazsab/miniconda3/envs/gfla/lib/python3.6/site-packages/matplotlib/mpl-data/stylelib/_classic_test_patch.mplstyle.
You probably need to get an updated matplotlibrc file from
http://github.com/matplotlib/matplotlib/blob/master/matplotlibrc.template
or from the matplotlib source distribution
Traceback (most recent call last):
File "train.py", line 125, in
main()
File "train.py", line 34, in main
opt = TrainOptions().parse() # get training options
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/options/base_options.py", line 116, in parse
opt = self.gather_options()
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/options/base_options.py", line 76, in gather_options
model_option_setter = models.get_option_setter(model_name)
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/models/init.py", line 47, in get_option_setter
model_class = find_model_using_name(model_name)
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/models/init.py", line 30, in find_model_using_name
modellib = importlib.import_module(model_filename)
File "/Midgard/home/sanazsab/miniconda3/envs/gfla/lib/python3.6/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 994, in _gcd_import
File "", line 971, in _find_and_load
File "", line 955, in _find_and_load_unlocked
File "", line 665, in _load_unlocked
File "", line 678, in exec_module
File "", line 219, in _call_with_frames_removed
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/models/flow_model.py", line 3, in
from models.networks.block_extractor.block_extractor import BlockExtractor
File "/Midgard/home/sanazsab/virtual-tryon/dressing-in-order/models/networks/block_extractor/block_extractor.py", line 8, in
from block_extractor import block_extractor_cuda
ImportError: cannot import name 'block_extractor_cuda'

replace costume pictures

Thank you for the model provided,which has further improved the field of costume change.Recently,on the basis of the pre training model you provided,we replaced ancient costume and found that all ancient costume pictures have been replaced with tops.I wonder if you can provide some solutions.Thank you very much.

Number of output patches and the generated image quality

Hi there,

One thing I have observed when testing with images that look significantly different from those in the DeepFashion dataset is: at times the generated results look blurry and lose some high-frequency details.

I was thinking about increasing the number of discriminator output patches (ndf in the code) to potentially improve the image quality, particularly to preserve more high-frequency details.

Do you by chance have any insights on the relationship between the number of output patches and the generated image quality? I would like to know if there is a point where ndf is too high and introduces diminishing returns or even undesirable effects during training (as opposed to ndf=32 by default).

Thank you for your time,
Vivek

Questions and thoughts on model size and performance

First of all, thank you for this incredible project!

I would like to hear about some of your insights on the trade-off between model performance and model quality, especially with regards to DiOr. One thing that I have observed during some profiling experiments of the DiOr pipeline is that some of the models are relatively large and require a relatively large number of FLOPs during inference, which makes it unsuitable for some application scenarios. For example, among all models some of the largest would be the generator network (~16.5 million parameters) at the end of pipeline, the flow network (~6.6 million parameters), and the segment encoder network (~1.2 million parameters).

I dug into the aforementioned models’ architecture a bit, and at first glance I found that convolutions with large kernel sizes (5 or 7) are used at quite a few locations, such as inside the ContentEncoder and Decoder in the generator, and the ADGANEncoder component in the segment encoder network. Do you think it would be a good idea to change these convolution layers with large kernel sizes into a series/stack of smaller ones in order to boost model performance and quality? For example, a stack of 3x3 convolution layers with stride of 1 would have the same receptive field as one 7x7 convolution layer, and not only do they have fewer parameters (3*(3^2C^2)) than the 7x7 convolution layer (7^2C^2), they will also give the model more non-linearities due to the greater depth.

Another idea that I have been toying around is the possibility of using separable convolutions like the ones used in MobileNets in order to reduce model size and latency. Nevertheless, I don’t know if using the separation convolution strategy would have lead a noticeable impact on the quality of the results produced by the DiOr models. I would really love to hear your opinions and thoughts on this.

Thanks a lot for the great work again!

Cannot reproduce results shown in the Colab demo notebook

Hi there,

I tried running the demo notebook on both Colab and on my local machine but could not reproduce the results shown in the Colab demo notebook, here are some of the results from my end along with the original ones shown in the Colab notebook for comparisons. The fit looks correct in general, but the head and the skin tone are distorted and could not achieve the same level of fidelity as the ones shown in the original notebook. Do you by chance know why this might be happending and what I should do in order to reproduce the results you had in the demo notebook? Thank you very much in advance!

PyTorch version on Google Colab: 1.10.0+cu111
PyTorch version on local machine: 1.10.1+cu113

Original output:
image
My output:
image

Original output:
image
My output:
image

Original output:
image
My output:
image

Original output:
image
My output:
image

Testing on Custom Image

Hi @cuiaiyu , Thanks a lot for this great work.
I'm working on Cloth Virtual Try-On as my Final Year Project.
The demo worked fine for me but currently I'm facing some issues in performing virtual try-on on my own image.
Steps I followed:

  1. Resized by full size image .jpg to 750x1101 pixels (as all the images in test folder are of this dimension) and added it to test folder.

  2. Ran openpose on the image and obtained the keypoints in .json file, manually separated x and y keypoints as (x0, y0, c0, x1, y1, c1, ....) and added the file name along with 2D_pose_keypoint y and x keypoints respectively in fasion-annotation-test.csv .

  3. Using SCHP found the human parsing and added it to testM_lip.

  4. Added image name in test.lip and standard_test_anns.txt under print just for testing.

  5. After that I just ran the demo.ipynb and got the following error in data loading step.
    image

I tried a lot to resolve this error but I'm unable to get it also I'm approaching the deadline. Kindly help me to test the model on custom image.

Also I'm unable to understand the use of fasion-pairs-test.csv while running demo.

Hopeful for your kind reply.
Thanks a lot Cuiaiyu !!!

Originally posted by @Djvnit in #21 (comment)

got NoneType during running the demo.ipynb

Hi Aiyu Cui,
When I was running the pose transfer part of demo.ipynb file, I found something wrong with the pose tensor.
(I finished the training process and no error occured.)

Traceback (most recent call last):
  File "demo.py", line 158, in <module>
    plot_img(pimg, gimgs, oimgs, gen_img, pose)
  File "demo.py", line 86, in plot_img
    if pose != None:
TypeError: ne() received an invalid combination of arguments - got (NoneType), but expected one of:
 * (Tensor other)
      didn't match because some of the arguments have invalid types: (NoneType)
 * (Number other)
      didn't match because some of the arguments have invalid types: (NoneType)

Then I printed the 'pose', and found it was mostly invalid.

tensor([[[0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]],

        [[0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]],

        [[0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]],

        ...,

        [[0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 9.8091e-45,
          1.4013e-45, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 2.6625e-44,
          2.8026e-45, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 7.0065e-44,
          8.4078e-45, 1.4013e-45],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]],

        [[4.8051e-42, 3.6002e-41, 2.6235e-40,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [1.4000e-41, 1.0490e-40, 7.6443e-40,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [3.9678e-41, 2.9728e-40, 2.1663e-39,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]],

        [[0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 5.6037e-37,
          8.5935e-38, 1.2818e-38],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 1.6328e-36,
          2.5040e-37, 3.7347e-38],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 4.6272e-36,
          7.0960e-37, 1.0584e-37],
         ...,
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00],
         [0.0000e+00, 0.0000e+00, 0.0000e+00,  ..., 0.0000e+00,
          0.0000e+00, 0.0000e+00]]], device='cuda:0')

Sorry for distrubing you, and look forward to your suggestion.

Pretrained weights for flownet.pt

Hi Aiyu,

Thanks for publishing such an interesting work!

I was playing with demo.ipynb, but got stuck at the point where we need to put the path for the pretrained flownet. The pre-trained models you shared only have three files - latest_net_Flow.pth, latest_net_E_attr.pth, and latest_net_G.pth. Are we supposed to put latest_net_Flow.pth for opt.flownet_path?

I tried this way but got some results inconsistent with yours. For example, this is the output for Layering - Single.
image

cf. I used img.zip(low-resolution images), and DIOR_64.

Error when running demo

Hi!Where is the flownet.pt model downloaded? An error occurred when running the demo code.
image

Missing images in dtd

Attempting the demo notebook.

Under Setup, first cell it's failing with.

   2842     if filename:
-> 2843         fp = builtins.open(filename, "rb")
   2844         exclusive_fp = True
   2845 

FileNotFoundError: [Errno 2] No such file or directory: '/content/dressing-in-order/dtd/images/chequered/chequered_0052.jpg'

Also just before that cell, I got return code of -1, not sure if this is related.

---------- Networks initialized -------------
[Network E_attr] Total number of parameters : 1.191 M
[Network G] Total number of parameters : 16.501 M
[Network VGG] Total number of parameters : 0.113 M
[Network Flow] Total number of parameters : 6.608 M
-----------------------------------------------
[tensorboard] init tensorboard @ checkpoints/DIOR_64/test
-1

Lastly, can you please guide on how can I generate "train/val split and keypoints from GFLA and PATN" for my own dataset.

Runtime Error

Environment- Ubuntu 20.04
GPU - Envidia T4 & V100 (tried on both)
Cuda - 11
Pytorch 1.0.0

requirements.txt had some library (given local link) I commented those.

Rest everything worked fine. I exported .ipynb file to py file and ran I got this error. When I googled one blog said this error is because this GPU not supported, is there any specific GPU requirement. Please advise

WhatsApp Image 2021-10-19 at 9 17 33 PM

Installation issues with requirements.txt

Hi there,

When I run the command: pip install -r requirements.txt, I run into some issues:

I noticed in "requirements.txt" that there are filepaths included next to some of the dependencies we need to install (cffi, Pillow, pycparser, and six); I removed them and the installations for these dependencies still worked. Is this ok or are there specific versions of these dependencies that we have to install?

My next issue is that for the following dependencies

mkl-fft==1.2.0
mkl-random==1.1.1
mkl-service==2.3.0

I get "No matching distribution found for [dependency]". I tried removing the version numbers for each and the installations proceeded successfully. Is this ok?

Thanks in advance!

no images are printed。。

image

Thank u so much in advance❤❤❤After I set the dataset as u say , then I run the demo , no error but no images are printed...

Here's the warnings, I tried to change align_corners=False to align_corners=True in .\torch\nn\functional.py , but it's useless...

C:\Users\75643\miniconda3\envs\gfla\lib\site-packages\torch\nn\functional.py:3636: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details.
  "See the documentation of nn.Upsample for details.".format(mode)
C:\Users\75643\miniconda3\envs\gfla\lib\site-packages\torch\nn\functional.py:4007: UserWarning: Default grid_sample and affine_grid behavior has changed to align_corners=False since 1.3.0. Please specify align_corners=True if the old behavior is desired. See the documentation of grid_sample for details.
  "Default grid_sample and affine_grid behavior has changed "
C:\Users\75643\Desktop\0postgraduate\1paper\0_DiOr_repo\dressing-in-order-main\utils\pose_utils.py:91: FutureWarning: circle is deprecated in favor of disk.circle will be removed in version 0.19
  yy, xx = circle(joint[0], joint[1], radius=radius, shape=img_size)
Clipping input data to the valid range for imshow with RGB data ([0..1] for floats or [0..255] for integers).

Test for high resoluton images

I have two images with size 768x1024. How i can test try on but still keep high resolution ?. Do i need to train model with 768x1024 before test it ?.

What's the version of openpose?

Please provide the details of the openpose version, it seems that the version of the openpose would affact the demo result.

All sections below Setup produce errors in the demo

Hello, I have reached the sections below "Setup" in the demo, but they produce an error when I try to run them.

"Pose Transfer" produces the following:
TypeError Traceback (most recent call last)
in ()
5 # generate
6 pimg, gimgs, oimgs, gen_img, pose = dress_in_order(model, pid, pose_id=pose_id)
----> 7 plot_img(pimg, gimgs, oimgs, gen_img, pose)

in plot_img(pimg, gimgs, oimgs, gen_img, pose)
41
42 def plot_img(pimg=[], gimgs=[], oimgs=[], gen_img=[], pose=None):
---> 43 if pose != None:
44 import utils.pose_utils as pose_utils
45 print(pose.size())

TypeError: ne() received an invalid combination of arguments - got (NoneType), but expected one of:

  • (Tensor other)
    didn't match because some of the arguments have invalid types: (!NoneType!)
  • (Number other)
    didn't match because some of the arguments have invalid types: (!NoneType!)

"Try-On: Tucking in" produces the following:
RuntimeError Traceback (most recent call last)
in ()
6
7 # tuck in (dressing order: hair, top, bottom)
----> 8 pimg, gimgs, oimgs, gen_img, pose = dress_in_order(model, pid, gids=gids, order=[2,5,1])
9 plot_img(pimg, gimgs, gen_img=gen_img, pose=pose)
10

in dress_in_order(model, pid, pose_id, gids, ogids, order, perturb)
89 seg = model.encode_single_attr(gimg[None], gparse[None], pose[None], to_pose[None], i=gid[2])
90 gsegs[gid[2]] = seg
---> 91 gimgs += [gimg * (gparse == gid[2])]
92
93 # encode garment (overlay)

RuntimeError: expected type torch.cuda.FloatTensor but got torch.cuda.ByteTensor
"Layering - Single (dress in order)" produces the following error:
RuntimeError Traceback (most recent call last)
in ()
2 ogids = [('print', 2, 5)]
3 # tuck in
----> 4 pimg, gimgs, oimgs, gen_img, pose = dress_in_order(model, pid, ogids=ogids)
5 plot_img(pimg, gimgs, oimgs, gen_img, pose)

in dress_in_order(model, pid, pose_id, gids, ogids, order, perturb)
97 for gid in ogids:
98 oimg, oparse, pose = load_img(gid, ds)
---> 99 oimgs += [oimg * (oparse == gid[2])]
100 seg = model.encode_single_attr(oimg[None], oparse[None], pose[None], to_pose[None], i=gid[2])
101 over_gsegs += [seg]

RuntimeError: expected type torch.cuda.FloatTensor but got torch.cuda.ByteTensor

"Layering - Multiple (dress in order)", "Texture Transfer", "Reshaping", "Content Removal" also produces the similar runtime error, I expect if one of them is fixed, the others will be as well, but I'm not sure what is causing the issue

Run demo dataset

hi
I want to get output from demo notebook, and I need to download the dataset to do this. But in the link you mentioned in the repo, there are 5 directories and I'm confused about which one should be used. These are the folders inside the provided link:
Screenshot (509)

Could you possibly help me with it?

Some questions about the content of the paper?

Hello! The V1 and V2 versions of the paper differ greatly in Body representation . What kind of implementation effect is good? How do I get M (fg) in V1? Are the current implementations implemented according to the latest V2? Thank you for your work.

Train on last stage error (KeyError: 'block0.model.1.weight')

I'm running command sh ./scripts/run_train.sh . Everything is fine until last train run, below is my last train in file run_train.sh and error image:

python train.py --model dior \ --name $NAME --dataroot $DATAROOT \ --batch_size 8 --lr 1e-5 --init_type orthogonal \ --loss_coe_seg 0.1 \ --netG $NET_G --ngf $NGF \ --netD gfla --ndf 64 --n_layers_D 4 \ --n_epochs 240002 --n_epochs_decay 60000 --lr_update_unit 4000 \ --print_freq 200 --display_freq 10000 --save_epoch_freq 10000 --save_latest_freq 2000 \ --n_cpus 16 --gpu_ids 0,1,2,3 --continue_train \ --epoch iter_160000 --epoch_count 160001 \ --flownet_path $PRETRAINED_FLOWNET_PATH \ --random_rate 0.8 --perturb

Screen Shot 2022-02-16 at 01 14 11

custom image openpose keypoints

I am testing the custom image. I ran openpose, so I got keypoints json file. but i think it's too big.
like
x : [445, 376, 189, 111, 153, 556, 589, 574, 282, 279, -1, 463, -1, -1, 403, 466, 324, -1]
y: [180, 382, 373, 655, 884, 391, 697, 941, 914, 1097, -1, 929, -1, -1, 138, 141, 147, -1]

how can i convert this?
should I use load_pose_from_json code? If then, when i get heatmap value, what should I do next?

some trouble when running demo

Hi! I successfully practiced the texture transfer in your demo, and I found it very interesting. But when I try to use only a texture image instead of a character image as the source texture, I encounter difficulties, how can I achieve this?I want to achieve the same result as in your paper.Thank you!
image

Generate Datasets error

Hi! Congratulations on the great work. I was trying to set up the repo on my windows 11 local machine but getting a list index out of bounds error while generating the dataset. Could you suggest possible solutions?

image

Results of demo output

The results of demo output are as follows:
图片1
图片2
图片3
图片4
Hello, how to improve the above effect?

  1. The semantic model adopted has no mask information of the neck. What do you suggest to do with the neck mask?

  2. The code distinguishes hair from hat, which is set as background information. Would it be better to combine hat and hair information?

  3. The resolution of the result is low and the image quality is not clear. Is there any magnification to improve the resolution?

  4. From the test results, the face information is inconsistent; Is it recommended to add facial information when changing hair?

python generate_fashion_datasets.py creates empty directories

Hi, when I run python generate_fashion_datasets.py. Two empty directories called train and test are created. No images are added inside them. I changed the data root folder to the one I made. My folder contains these files:

  • testM_lip
  • trainM_lip
  • fashion-annotation-test.csv
  • fashion-annotation-train.csv
  • fashion-pairs-test.csv
  • fashion-pairs-train.csv
  • standard_test_anns.text
  • test.lst
  • train.lst

I don't think I'm missing any files, so I don't know why generate_fashion_datasets.py doesn't add images to the two folders it creates.

Installing local-attn-reshape-cuda Requirement

Hi,

I installed based on the guidance in GFLA, but still there is the below error
ERROR: Could not find a version that satisfies the requirement local-attn-reshape-cuda==0.0.0 (from versions: none)
ERROR: No matching distribution found for local-attn-reshape-cuda==0.0.0

Thanks for your prompt response in advance.

Best
Sanaz

cannot reproduce the result

Hi Aiyu,

I followed exactly the same process as you mentioned in the github (I didn't install the cuda function in GFLA as I only need to run the inference stage, and I set --frozen_flownet=True). But the generated results are like this:
generated_2
generated_3

AssertionError: data is not a valid directory

Hi ! Cui , the work is really COOOOL ! Thanks for ur code. But after setting the environment,I am gonna set the dataset,when I Run python tools/generate_fashion_dataset.py --dataroot $DATAROOT to split the data. (which was the step3 in the Dataset)I met this error...Hope u can help me,thanks a lot❤


Traceback (most recent call last):
File ".\tools\generate_fashion_datasets.py", line 77, in
make_dataset(args.dataroot)
File ".\tools\generate_fashion_datasets.py", line 31, in make_dataset
assert os.path.isdir(dataroot), '%s is not a valid directory' % dataroot
AssertionError: data is not a valid directory


Do I need to change the dataroot in the demo.ipynb?
dataroot = '/shared/rsaas/aiyucui2/inshop/fashion_yifang'

FID value less than paper

Hi @cuiaiyu ,

Thanks for sharing your work. I was trying to reproduce the FID values for 256*256 images given in the paper using your code. However, I got a lesser FID value of 12.25 instead of 13.10 mentioned in paper.

For glfa also, I am getting a value of 9.87 instead of 10.57 which you also mentioned in gfla comment. Can you let me know how was that issue solved?

flownet.pt not found

Hi,
Thank You so much for sharing this amazing work. I was thinking to implement your work but I couldn't find flownet.pt. Can you please share the model
Thanks

Real time results are not matching

I was trying the inference of some images form standard_test_anns.txt. I got the keypoints from openpose and the mask from SCHP. Then I used dressing in order inside demo.ipynb and changed the gids. The results from demo.ipynb are perfect but my results are not up-to the mark. Also the keypoints from openpose is also not matching with the dataset keypoints by GFLA

This is the result generated by demo.ipynb
a111

This is my result.
a112

Could you please suggest where I can generate the keypoints to match the results? Or is there anything I missed out?

Thanks in advance.

Purpose of warm up

Hi,

Thanks for the great work.

I found the model's training requires warm up of the flow estimation model. What's the purpose of this step?
And how to design the warm up?

Results are not displayed

Hello, thank you so much for this great work.
I have a problem trying to test the demo on google colab, when I execute the Try-On: Tucking in although no error is showed I can not see any result
image

I also get this when I run the code before, I dont know if this can be related
image

Test by my own

Thank You so much for this great work,
How can I test in my own image?

the groups and the persons in them

hello, first of all i would like to congratulate you for the great work.
I have a question about the used groups(pattern, plaid...), i couldn't understand how were they created and where ? and how are they used to extract poses ?

AssertionError: during running the demo.ipynb

I was just tried running the demo.ipynb file, and I got the error.
complete error log:

AssertionError Traceback (most recent call last) <ipython-input-3-0d7fae2cb9db> in <module>() ----> 1 model = DIORModel(opt) 2 model.setup(opt) /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/dior_model.py in __init__(self, opt) 9 class DIORModel(DIORBaseModel): 10 def __init__(self, opt): ---> 11 DIORBaseModel.__init__(self, opt) 12 self.netE_opt = opt.netE 13 self.frozen_flownet = opt.frozen_flownet /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/dior_base_model.py in __init__(self, opt) 21 self.n_style_blocks = opt.n_style_blocks 22 # init_models ---> 23 self._init_models(opt) 24 25 # loss /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/dior_model.py in _init_models(self, opt) 59 60 def _init_models(self, opt): ---> 61 super()._init_models(opt) 62 self.model_names += ["Flow"] 63 if opt.frozen_flownet: /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/dior_base_model.py in _init_models(self, opt) 65 self.frozen_models = ["VGG"] 66 self.visual_names = ['from_img', 'fake_B', 'to_img'] ---> 67 self.netVGG = networks.define_tool_networks(tool='vgg', load_ckpt_path="", gpu_ids=opt.gpu_ids) 68 69 # netG /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/networks/__init__.py in define_tool_networks(tool, load_ckpt_path, gpu_ids, init_type, init_gain) 66 print("[init] init pre-trained model %s." % tool) 67 ---> 68 return init_net(net, gpu_ids=gpu_ids, do_init_weight=False) 69 70 def define_E(input_nc, output_nc, netE, ngf=64, n_downsample=3, norm_type='none', relu_type='relu', frozen_flownet=True, init_type='normal', init_gain=0.02, gpu_ids=[]): /Users/soumyadeeproy/Downloads/dressing-in-order-main/models/networks/base_networks.py in init_net(net, init_type, init_gain, gpu_ids, do_init_weight) 101 if len(gpu_ids) > 0: 102 # import pdb; pdb.set_trace() --> 103 assert(torch.cuda.is_available()) 104 105 net = net.cuda() AssertionError:

seems like the error is inside the dior_model file

How to Train on High Resolution

Hi, thanks for the great work! I am curious about the results with high resolution, like 512*358, so I want to train by my own, but I am not so sure about how to change the training process. Could you please give me some advice?

Error in model = DIORModel(opt)

Hi Aiyu Cui,
I have been following the topic since 2017 and dressing-in-order brings a lot of new features like tuck-in into the picture. Cheers for that. However, I have tried to recreate this framework on Google Colab & not been able to figure my way out. The notebook that I've used: link_to_nb

Tesla K80
NVIDIA-SMI 510.39.01 Driver Version: 460.32.03 CUDA Version: 11.2

While building custom CUDA modules was smooth, I am not sure about CUDA 11.2 along with torch 1.0.0

When setting up the dior_mdoel, the below error pops.

load vgg ckpt from torchvision dict.
[init] init pre-trained model vgg.
initialize network with orthogonal

---------------------------------------------------------------------------

RuntimeError                              Traceback (most recent call last)

<ipython-input-14-81abdc6faa32> in <module>
     29 
     30 # create model
---> 31 model = DIORModel(opt)
     32 model.setup(opt)

14 frames

/content/dressing-in-order/models/dior_model.py in __init__(self, opt)
      9 class DIORModel(DIORBaseModel):
     10     def __init__(self, opt):
---> 11         DIORBaseModel.__init__(self, opt)
     12         self.netE_opt = opt.netE
     13         self.frozen_flownet = opt.frozen_flownet

/content/dressing-in-order/models/dior_base_model.py in __init__(self, opt)
     21         self.n_style_blocks = opt.n_style_blocks
     22         # init_models
---> 23         self._init_models(opt)
     24 
     25         # loss

/content/dressing-in-order/models/dior_model.py in _init_models(self, opt)
     59 
     60     def _init_models(self, opt):
---> 61         super()._init_models(opt)
     62         self.model_names += ["Flow"]
     63         if opt.frozen_flownet:

/content/dressing-in-order/models/dior_base_model.py in _init_models(self, opt)
     72                                       n_style_blocks=opt.n_style_blocks, n_human_parts=opt.n_human_parts, netG=opt.netG,
     73                                       norm=opt.norm_type, relu_type=opt.relu_type,
---> 74                                       init_type=opt.init_type, init_gain=opt.init_gain, gpu_ids=self.gpu_ids)
     75 
     76         self.netE_attr = networks.define_E(input_nc=3, output_nc=opt.style_nc, netE=opt.netE, ngf=opt.ngf, n_downsample=2,

/content/dressing-in-order/models/networks/__init__.py in define_G(input_nc, output_nc, ngf, latent_nc, style_nc, n_downsampling, n_style_blocks, n_human_parts, netG, norm, relu_type, init_type, init_gain, gpu_ids, **kwargs)
     82             norm_type=norm, relu_type=relu_type, **kwargs
     83             )
---> 84     return init_net(net, init_type, init_gain, gpu_ids)
     85 
     86 def define_D(input_nc, ndf, netD, n_layers_D=3, norm='batch', use_dropout=True, use_sigmoid=False, init_type='normal', init_gain=0.02, gpu_ids=[]):

/content/dressing-in-order/models/networks/base_networks.py in init_net(net, init_type, init_gain, gpu_ids, do_init_weight)
    107         net = torch.nn.DataParallel(net, gpu_ids)  # multi-GPUs
    108     if do_init_weight:
--> 109         init_weights(net, init_type, init_gain=init_gain)
    110     return net
    111 

/content/dressing-in-order/models/networks/base_networks.py in init_weights(net, init_type, init_gain)
     88 
     89     print('initialize network with %s' % init_type)
---> 90     net.apply(init_func)  # apply the initialization function <init_func>
     91 
     92 def init_net(net, init_type='normal', init_gain=0.02, gpu_ids=[], do_init_weight=True):

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    240         """
    241         for module in self.children():
--> 242             module.apply(fn)
    243         fn(self)
    244         return self

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    240         """
    241         for module in self.children():
--> 242             module.apply(fn)
    243         fn(self)
    244         return self

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    240         """
    241         for module in self.children():
--> 242             module.apply(fn)
    243         fn(self)
    244         return self

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    240         """
    241         for module in self.children():
--> 242             module.apply(fn)
    243         fn(self)
    244         return self

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    240         """
    241         for module in self.children():
--> 242             module.apply(fn)
    243         fn(self)
    244         return self

/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py in apply(self, fn)
    241         for module in self.children():
    242             module.apply(fn)
--> 243         fn(self)
    244         return self
    245 

/content/dressing-in-order/models/networks/base_networks.py in init_func(m)
     78                 init.kaiming_normal_(m.weight.data, a=0, mode='fan_in')
     79             elif init_type == 'orthogonal':
---> 80                 init.orthogonal_(m.weight.data, gain=init_gain)
     81             else:
     82                 raise NotImplementedError('initialization method [%s] is not implemented' % init_type)

/usr/local/lib/python3.7/dist-packages/torch/nn/init.py in orthogonal_(tensor, gain)
    354 
    355     # Compute the qr factorization
--> 356     q, r = torch.qr(flattened)
    357     # Make Q uniform according to https://arxiv.org/pdf/math-ph/0609050.pdf
    358     d = torch.diag(r, 0)

RuntimeError: cuda runtime error (11) : invalid argument at /pytorch/aten/src/THC/generic/THCTensorMathPairwise.cu:225

link_to_cell
Please look into this, Thanks :)

Suspicious flownet warmup logs

During the flow net warm up. I am getting the following logs. I am not understanding why all the values are zero.

[flownet_warmup][iter-50]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-100]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-150]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-200]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-250]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-300]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-350]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-400]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-450]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-500]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-550]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-600]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-650]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-700]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-750]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-800]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-850]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-900]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-950]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1000]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1050]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1100]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1150]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1200]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1250]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1300]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1350]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1400]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1450]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1500]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1550]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1600]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1650]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1700]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1750]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1800]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1850]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1900]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-1950]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
[flownet_warmup][iter-2000]G_GAN_pose: 0.0000, G_GAN_content: 0.0000, D_real_pose: 0.0000, D_fake_pose: 0.0000, D_real_content: 0.0000, D_fake_content: 0.0000, rec: 0.0000, per: 0.0000, sty: 0.0000, seg: 0.0000, flow_reg: 0.0000, flow_cor: 2.5285, 
saving the latest model (total_iters 2000)
End of iter 2000 / 120000        Time Taken: 1220 sec
at 2000, compute visuals

These are my training parameters.

----------------- Options ---------------
               batch_size: 32                             
                    beta1: 0.5                           
                    beta2: 0.999                         
          checkpoints_dir: checkpoints                   
           continue_train: True                          	[default: False]
                crop_size: 256                           
                 dataroot: data/fashion/                 	[default: data]
             display_freq: 2000                          
                    epoch: latest                        
              epoch_count: 1                             
             flownet_path:                               
               frozen_enc: False                         
           frozen_flownet: False                         
            frozen_models:                               
                g2d_ratio: 0.1                           
                 gan_mode: lsgan                         
                  gpu_ids: 0,1,2,3                         	[default: 0]
                  img_dir: img_highres                   
                init_gain: 0.02                          
                init_type: orthogonal                    	[default: kaiming]
                  isTrain: True                          	[default: None]
                load_iter: 0                             	[default: 0]
             loss_coe_GAN: 1                             
        loss_coe_flow_cor: 2.0                           
        loss_coe_flow_reg: 0.001                         
             loss_coe_per: 0.0                           	[default: 0.2]
             loss_coe_rec: 0.0                           	[default: 2]
             loss_coe_seg: 0.1                           
             loss_coe_sty: 0.0                           	[default: 200]
                       lr: 0.0001                        	[default: 0.001]
           lr_decay_iters: 50                            
                lr_policy: linear                        
           lr_update_unit: 10000                         
           max_batch_size: 16                            
                    model: flow                          	[default: adgan]
                   n_cpus: 8                             	[default: 4]
             n_downsample: 2                             
                 n_epochs: 60000                         
           n_epochs_decay: 60000                         
            n_human_parts: 8                             
                   n_kpts: 18                            
               n_layers_D: 3                             
           n_style_blocks: 4                             
                     name: flownet_warmup                	[default: experiment_name]
                      ndf: 64                            
                     netD: resnet                        
                     netE: adgan                         
                     netG: adgan                         
                      ngf: 64                            
               no_dropout: False                         
            no_trial_test: True                          	[default: False]
                norm_type: instance                      
                  perturb: False                         
                    phase: train                         
                pool_size: 50                            
               print_freq: 50                            	[default: 100]
              progressive: False                         
              random_rate: 1                             
                relu_type: leakyrelu                     
             save_by_iter: False                         
          save_epoch_freq: 20000                         
         save_latest_freq: 2000                          
             segm_dataset:                               
                   square: False                         
                 style_nc: 64                            
                   suffix:                               
                  tex_dir: dtd/images                    
                  verbose: False                         
                   warmup: False                         
----------------- End -------------------

Testing with custom images of garment only

First of all, thanks for the amazing project!

My teammates and I are using your work in part of our course project, and we are using the FashionIQ dataset, which is mostly consisted of garment-only images, for inference on your pretrained model
Can you give us a more detailed explanation of how to preprocess the dataset and run the inference in the case of garment-only images?

We found you mentioned that P_{g_k} is going to be an empty heatmap when the image is garment only,
but I'm not really sure how can we implement it.
And it seems like the parser does not work well on garment-only images, so if there are any other methods we can try to parse the garment from the background.

Also, we are struggling with the face overfitting issue and would like to ask if using garment-only images will help resolve the issue since the pose is not transferred.

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.