IHe-KaiI / DressCode

DressCode: Autoregressively Sewing and Generating Garments from Text Guidance.
188 stars 6 forks source link

How to get the final image with textures and different pose? #6

Open NagabhushanSN24 opened 2 months ago

NagabhushanSN24 commented 2 months ago

Hi,

I am able to setup Maya, Qualoth and Blender. I am able to run python nn/UI_chat.py --sim and if I give some text description, the pipeline works fine and outputs something. I'm getting the garment mesh in pred_0_sim.obj, garment + T-pose human mesh in pred_0_sim_raw.obj, texture files in texture_combined.png, etc. However, pred_0_camera1.png is a 0KB file and render.mp4 is a 1KB file.

How do I get the final images you have shown in the paper?

Some logs if they help:

qt.svg: Cannot open file ':/expression.svg', because: No such file or directory
FXLicense : license server ip address : 123.123.123.123
FXLicense : connecting to the license server failed.
FXLicense : license error code : -2
FXLicense : temporal evaluation license activated
Qualoth : Evaluation license
Error: Failed to open IFF file for reading : C:/Users/ADMINI~1/AppData/Local/Temp/2//maya380000002DFC3AF6800.iff
Warning! Using result of ChoosePixelFormat.
Win32 Error# (127): The specified procedure could not be found.
Error   : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FFF19491F21
Module  : VCRUNTIME140.dll
Thread  : 000010ec
Writing: C:\Users\ADMINI~1\AppData\Local\Temp\2\blender.crash.txt
NagabhushanSN24 commented 2 months ago

I was able to copy the files from windows server machine to my local macbook and the blender command to generate the video.

/Applications/Blender.app/Contents/MacOS/Blender -b -P ./nn/blender/texture_multi.py -- .../240812-06-21-23/000/pred_0/render_info.json

This generates the render.mp4 file. So, I guess it is some issue with my windows server machine.

However, I still don't know how to get pred_0_camera1.png.

Also, how do I animate the human? Do I have to do it manually by importing the human model into Clo3D, or is there an example script to do that via terminal/API?

IHe-KaiI commented 2 months ago

Hi!

NagabhushanSN24 commented 2 months ago

Thank you for the clarification. Any idea why pred_0_camera1.png is not getting rendered correctly? Any pointers that I can check? I am very new to these 3D softwares (Maya, Qualoth).

IHe-KaiI commented 2 months ago

Can you try python nn/evaluation_scripts/predict_class.py -c ./models/infer.yaml -s? It only generates sewing patterns and -s enables simulation. Check your output and the raised errors.

NagabhushanSN24 commented 2 months ago

Thanks, I'm getting the following error now:

Traceback (most recent call last):
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\nn\simulation\sim.py", line 90, in <module>
    Sim.simulation_single(command_args.data)
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\nn\simulation\sim.py", line 60, in simulation_single
    mymaya.simulation.single_file_sim(self.system_config, self.props, no_stitch=False)
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\packages\mayaqltools\simulation.py", line 33, in single_file_sim
    template_simulation(pattern_spec_norm,
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\packages\mayaqltools\simulation.py", line 210, in template_simulation
    garment.load(
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\packages\mayaqltools\mayascene.py", line 81, in load
    self.stitch_panels()
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\packages\mayaqltools\mayascene.py", line 124, in stitch_panels
    self._maya_curve_name(stitch[1]))
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\DressCode\packages\mayaqltools\mayascene.py", line 719, in _maya_curve_name
    return self.MayaObjects['panels'][panel_name]['edges'][edge_id]

Attaching the complete logs for reference. DressCodeLogs.txt

IHe-KaiI commented 2 months ago

From your logs, I see that Maya successfully saved images in the folder.

Rendering saved to 
C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\runs\testing\test0005\240812-11-10-22\000\pred_0\pred_0_camera1
...
Rendering saved to 
C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\runs\testing\test0005\240812-11-10-22\001\pred_0\pred_0_camera1
...
Rendering saved to 
C:\Users\Administrator\Desktop\nagabhushan\workspace\clothing_humans\literature\006_DressCode\runs\testing\test0005\240812-11-10-22\002\pred_0\pred_0_camera1

Can you check whether your outputs pred_0_camera1.png are still 0KB?

The error you mentioned is sometimes our SewingGPT will generate wrong patterns like the wrong number of edge id, then our script will automatically re-generate it.

NagabhushanSN24 commented 2 months ago

Ah okay. Gotcha. But the pred_0_camera1.png image is still 0KB for all the three samples.

IHe-KaiI commented 2 months ago

Normally it will output Finished experiment after the simulation (see code). I tried to compare my logs and found I had no FXLicense : connecting to the license server failed. But since you've gotten the simulated mesh pred_0_sim.obj, I guess it may not be the core issue. I didn't meet that issue before, maybe you can debug here (render code).

NagabhushanSN24 commented 2 months ago

Cool, thanks for the pointer! I'll try to debug that.