TingtingLiao / TADA

[3DV 2024] Official Repository for "TADA! Text to Animatable Digital Avatars".
https://tada.is.tue.mpg.de
MIT License
280 stars 13 forks source link

How to download "ckpt_file" for anime.py? #4

Closed qxh123456789 closed 1 year ago

qxh123456789 commented 1 year ago

Thank you for your work! @YuliangXiu , I am trying to run the Animation demo. May I know where to download the files for ckpt_file below? I think it's the path to the pre-trained characters. I have downloaded TADA Extra Data and unzip it as ./data, but there is no checkpoints in it. And the code breaks at assert os.path.exists(ckpt_file) (L404 of anime.py).

https://github.com/TingtingLiao/TADA/blob/cad379771e66d3551476b6d873c106dc812a4089/apps/anime.py#L403

Also, I have download TADA 100 Characters and there is also no checkpoints, but there is a params.pt in each character's folder. However the key in these .pt files dict_keys(['v_offsets', 'betas', 'expression']) do not match the ones in the code. There should be a 'raw_albedo' key in addition to these, according to your code.

TingtingLiao commented 1 year ago

You can load the albedo from the texture image (which is included in the 100 characters) using the following script:

   albedo = cv2.imread(albedo_path, cv2.IMREAD_UNCHANGED)
    albedo = cv2.cvtColor(albedo, cv2.COLOR_BGR2RGB)
    albedo = albedo.astype(np.float32) / 255
    self.raw_albedo = torch.as_tensor(albedo)
qxh123456789 commented 1 year ago

Thank you for your answer! This solved it.