Fix some typing problems (#1940)

* Fix some typing problems

* nerfstudio.data typing error fixes

* Add tiny fixes

* Remove ABC from pipeline

* Prevent circular imports

* Tweak ModuleList typing

* TrainingCallbackAttributes cleanup

* Various minor nits

* More nits

* Run `ruff`

---------

Co-authored-by: Brent Yi <yibrenth@gmail.com>
This commit is contained in:
Jonáš KulhánekandBrent Yi authored and GitHub committed 2023-05-17 17:36:56 -07:00
1 parent c6111e377e
commit f481f5ebec
27 files changed
+154 -75

No files matched your search

+3 -3
View File
@@ -152,14 +152,14 @@ class RaySamples(TensorDataclass):
@overload
@staticmethod
def get_weights_and_transmittance_from_alphas(
alphas: Float[Tensor, "*batch num_samples 1"], weights_only: Literal[False] = False
) -> Tuple[Float[Tensor, "*batch num_samples 1"], Float[Tensor, "*batch num_samples 1"]]:
alphas: Float[Tensor, "*batch num_samples 1"], weights_only: Literal[True]
) -> Float[Tensor, "*batch num_samples 1"]:
...
@overload
@staticmethod
def get_weights_and_transmittance_from_alphas(
alphas: Float[Tensor, "*batch num_samples 1"], weights_only: Literal[True]
alphas: Float[Tensor, "*batch num_samples 1"], weights_only: Literal[False] = False
) -> Tuple[Float[Tensor, "*batch num_samples 1"], Float[Tensor, "*batch num_samples 1"]]:
...