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

Fix cli bug in high version of tyro #3567

Merged
merged 7 commits into from
Jan 21, 2025
Merged

Conversation

Tavish9
Copy link
Contributor

@Tavish9 Tavish9 commented Jan 10, 2025

In higher version of tyro(>0.9.3), the cli cannot recognize the following config definition:

"""Use the same proposal network. Otherwise use different ones."""
proposal_net_args_list: List[Dict] = field(
    default_factory=lambda: [
        {"hidden_dim": 16, "log2_hashmap_size": 17, "num_levels": 5, "max_res": 128, "use_linear": False},
        {"hidden_dim": 16, "log2_hashmap_size": 17, "num_levels": 5, "max_res": 256, "use_linear": False},
    ]
)

Reproduction:

ns-train nerfacto --pipeline.model.proposal-net-args-list.0.hidden-dim 1

  1. In typo==0.9.2:
image
  1. In typo>0.9.2:
image

@brentyi
Copy link
Collaborator

brentyi commented Jan 21, 2025

Hi @Tavish9 thanks for pointing this out and making this PR!

I made some changes, to summarize:

  • Fixed the bug upstream in tyro.
  • Bumped the minimum tyro version.
  • Bumped the minimum typeguard version, which is required by tyro.
  • Found that this caused problems with Nerfstudio's CI, since newer versions of typeguard aren't compatible with jaxtyping.
  • It seems unideal to keep a 3+ year old version of typeguard pinned indefinitely, so I switched jaxtyping's pytest hook. Running typeguard in CI seems unnecessary since we added static checking in Final typing fixes + add Pyright to CI #1944.

@brentyi brentyi merged commit 1dc2ebd into nerfstudio-project:main Jan 21, 2025
3 checks passed
@Tavish9
Copy link
Contributor Author

Tavish9 commented Jan 21, 2025

Hi @brentyi, thanks for the hard work! 🤗

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

Successfully merging this pull request may close these issues.

3 participants