Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: invalid literal for int() with base 10: 'hparams.txt' #91

Open
SSXXSSXX opened this issue Apr 25, 2024 · 2 comments
Open

ValueError: invalid literal for int() with base 10: 'hparams.txt' #91

SSXXSSXX opened this issue Apr 25, 2024 · 2 comments

Comments

@SSXXSSXX
Copy link

          > 1. assuming your individual submodules were trained with a checkpoint directory such as "/foo/submodule-0", /foo/submodule-1", etc, you'd pass in "/foo/submodule-" as the prefix and the merging script will iterate through all of the trained submodule directories.

https://github.com/cmusatyalab/mega-nerf/blob/main/scripts/merge_submodules.py#L34
I find it has some errors in this step:

My input checkpoint directory is "--ckpt_prefix logs/exp/ex-", but the root seems error:

Traceback (most recent call last):
  File "/home/paper/Desktop/meganerf/scripts/merge_submodules.py", line 113, in <module>
    main(_get_merge_opts())
  File "/home/paper/anaconda3/envs/mega-nerf/lib/python3.9/site-packages/torch/autograd/grad_mode.py", line 28, in decorate_context
    return func(*args, **kwargs)
  File "/home/paper/Desktop/meganerf/scripts/merge_submodules.py", line 51, in main
    version_dirs = sorted([int(x.name) for x in list(centroid_path.iterdir())], reverse=True)
  File "/home/paper/Desktop/meganerf/scripts/merge_submodules.py", line 51, in <listcomp>
    version_dirs = sorted([int(x.name) for x in list(centroid_path.iterdir())], reverse=True)
ValueError: invalid literal for int() with base 10: 'hparams.txt'

what the meaning of version_dirs ?

image

Could you please help me solve this problem? Thanks a lot.

Originally posted by @Kikihqq in #31 (comment)

@SSXXSSXX SSXXSSXX changed the title > 1. assuming your individual submodules were trained with a checkpoint directory such as "/foo/submodule-0", /foo/submodule-1", etc, you'd pass in "/foo/submodule-" as the prefix and the merging script will iterate through all of the trained submodule directories. ValueError: invalid literal for int() with base 10: 'hparams.txt' Apr 25, 2024
@shibjeuiwuyi
Copy link

ValueError: invalid literal for int() with base 10: 'hparams.txt',How did you solve this problem, can you share?

@ghazalehgholinejad
Copy link

please share the response of this problem. we really got stuck in this problem and I don't have any idea for solving it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants