david-svitov / HAHA

HAHA: Highly Articulated Gaussian Human Avatars with Textured Mesh Prior
89 stars 9 forks source link

AttributeError: 'Struct' object has no attribute 'vt' #7

Closed judy-zhong closed 2 months ago

judy-zhong commented 2 months ago

Thanks for your nice work! I encounter the following bugs. Could you give me some instructions? Traceback (most recent call last):

 File "/mnt/c/Users/24320/Desktop/RTavatar/HAHA/main.py", line 151, in <module>
    main(sys.argv)
  File "/mnt/c/Users/24320/Desktop/RTavatar/HAHA/main.py", line 127, in main
    runner = instantiate_from_config(config.runner)
  File "/mnt/c/Users/24320/Desktop/RTavatar/HAHA/utils/general.py", line 34, in instantiate_from_config
    return get_obj_from_str(config["target"])(**config.get("params", dict()))
  File "/mnt/c/Users/24320/Desktop/RTavatar/HAHA/runners/train_gaussians.py", line 126, in __init__
    self._load_smplx_model(smplx_path, gender)
  File "/mnt/c/Users/24320/Desktop/RTavatar/HAHA/runners/train_gaussians.py", line 188, in _load_smplx_model
    self._uv = torch.Tensor(data_struct.vt).contiguous()
AttributeError: 'Struct' object has no attribute 'vt'
ERROR conda.cli.main_run:execute(124): `conda run python /mnt/c/Users/24320/Desktop/RTavatar/HAHA/main.py` failed. (See above for error)
david-svitov commented 2 months ago

Hello! 'vt' must be contained in the SMPLX_*.npz file. Please tell me if you downloaded SMPLX from the official website. Make sure that the program finds npz and it is read correctly. Please tell me what attributes you can extract from the 'Struct', this will help to understand why the error occurs with 'vt'.

judy-zhong commented 2 months ago

Hi!I downloaded the SMPLX_*.npz file of version 1.1 from the official website of smplx. The screenshot below shows the content of my Struct. 微信图片_20240419174619

judy-zhong commented 2 months ago

I only modified the smplx_path in the YAML file to read the smplx file.

david-svitov commented 2 months ago

Very interesting. I just downloaded the file from the SMPLX website version 1.1 https://download.is.tue.mpg.de/download.php?domain=smplx&sfile=models_smplx_v1_1.zip Then ran the following code:

data = np.load("/home/dsvitov/Downloads/models_smplx_v1_1/models/smplx/SMPLX_FEMALE.npz", allow_pickle=True)
print(data.files)

I see 'vt' among the file contents. Could you check it the same way?

judy-zhong commented 2 months ago

I'm sorry for making this elementary mistake. I checked it, and then I got these parameters.