SYMBOL INDEX (1184 symbols across 88 files) FILE: launch.py class ColoredFilter (line 8) | class ColoredFilter(logging.Filter): method __init__ (line 31) | def __init__(self): method filter (line 34) | def filter(self, record): function main (line 42) | def main() -> None: FILE: load/make_prompt_library.py function main (line 422) | def main(): FILE: load/tets/generate_tets.py function generate_tetrahedron_grid_file (line 22) | def generate_tetrahedron_grid_file(res=32, root=".."): function convert_from_quartet_to_npz (line 33) | def convert_from_quartet_to_npz(quartetfile="cube_32_tet.tet", npzfile="... FILE: threestudio/__init__.py function register (line 4) | def register(name): function find (line 12) | def find(name): function warn (line 32) | def warn(*args, **kwargs): FILE: threestudio/data/co3d.py function _load_16big_png_depth (line 33) | def _load_16big_png_depth(depth_png) -> np.ndarray: function _load_depth (line 45) | def _load_depth(path, scale_adjustment) -> np.ndarray: function _get_1d_bounds (line 55) | def _get_1d_bounds(arr): function get_bbox_from_mask (line 60) | def get_bbox_from_mask(mask, thr, decrease_quant=0.05): function get_clamp_bbox (line 75) | def get_clamp_bbox(bbox, box_crop_context=0.0, impath=""): function crop_around_box (line 100) | def crop_around_box(tensor, bbox, impath=""): function resize_image (line 107) | def resize_image(image, height, width, mode="bilinear"): function similarity_from_cameras (line 132) | def similarity_from_cameras(c2w, fix_rot=False, radius=1.0): class Co3dDataModuleConfig (line 193) | class Co3dDataModuleConfig: class Co3dDatasetBase (line 218) | class Co3dDatasetBase: method setup (line 219) | def setup(self, cfg, split): method get_all_images (line 524) | def get_all_images(self): class Co3dDataset (line 528) | class Co3dDataset(Dataset, Co3dDatasetBase): method __init__ (line 529) | def __init__(self, cfg, split): method __len__ (line 532) | def __len__(self): method prepare_data (line 542) | def prepare_data(self, index): method __getitem__ (line 582) | def __getitem__(self, index): class Co3dIterableDataset (line 592) | class Co3dIterableDataset(IterableDataset, Co3dDatasetBase): method __init__ (line 593) | def __init__(self, cfg, split): method __iter__ (line 598) | def __iter__(self): method collate (line 602) | def collate(self, batch) -> Dict[str, Any]: class Co3dDataModule (line 675) | class Co3dDataModule(pl.LightningDataModule): method __init__ (line 676) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 680) | def setup(self, stage=None): method prepare_data (line 688) | def prepare_data(self): method general_loader (line 691) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 701) | def train_dataloader(self): method val_dataloader (line 706) | def val_dataloader(self): method test_dataloader (line 709) | def test_dataloader(self): method predict_dataloader (line 712) | def predict_dataloader(self): FILE: threestudio/data/image.py class SingleImageDataModuleConfig (line 30) | class SingleImageDataModuleConfig: class SingleImageDataBase (line 44) | class SingleImageDataBase: method setup (line 45) | def setup(self, cfg, split): method get_all_images (line 153) | def get_all_images(self): class SingleImageIterableDataset (line 157) | class SingleImageIterableDataset(IterableDataset, SingleImageDataBase): method __init__ (line 158) | def __init__(self, cfg: Any, split: str) -> None: method collate (line 162) | def collate(self, batch) -> Dict[str, Any]: method __iter__ (line 181) | def __iter__(self): class SingleImageDataset (line 186) | class SingleImageDataset(Dataset, SingleImageDataBase): method __init__ (line 187) | def __init__(self, cfg: Any, split: str) -> None: method __len__ (line 191) | def __len__(self): method __getitem__ (line 194) | def __getitem__(self, index): class SingleImageDataModule (line 215) | class SingleImageDataModule(pl.LightningDataModule): method __init__ (line 218) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 222) | def setup(self, stage=None) -> None: method prepare_data (line 230) | def prepare_data(self): method general_loader (line 233) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 238) | def train_dataloader(self) -> DataLoader: method val_dataloader (line 245) | def val_dataloader(self) -> DataLoader: method test_dataloader (line 248) | def test_dataloader(self) -> DataLoader: method predict_dataloader (line 251) | def predict_dataloader(self) -> DataLoader: FILE: threestudio/data/multiview.py function convert_pose (line 24) | def convert_pose(C2W): function convert_proj (line 32) | def convert_proj(K, H, W, near, far): function inter_pose (line 41) | def inter_pose(pose_0, pose_1, ratio): class MultiviewsDataModuleConfig (line 61) | class MultiviewsDataModuleConfig: class MultiviewIterableDataset (line 74) | class MultiviewIterableDataset(IterableDataset): method __init__ (line 75) | def __init__(self, cfg: Any) -> None: method __iter__ (line 176) | def __iter__(self): method collate (line 180) | def collate(self, batch): class MultiviewDataset (line 196) | class MultiviewDataset(Dataset): method __init__ (line 197) | def __init__(self, cfg: Any, split: str) -> None: method __len__ (line 356) | def __len__(self): method __getitem__ (line 359) | def __getitem__(self, index): method __iter__ (line 371) | def __iter__(self): method collate (line 375) | def collate(self, batch): class MultiviewDataModule (line 382) | class MultiviewDataModule(pl.LightningDataModule): method __init__ (line 385) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 389) | def setup(self, stage=None) -> None: method prepare_data (line 397) | def prepare_data(self): method general_loader (line 400) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 408) | def train_dataloader(self) -> DataLoader: method val_dataloader (line 413) | def val_dataloader(self) -> DataLoader: method test_dataloader (line 419) | def test_dataloader(self) -> DataLoader: method predict_dataloader (line 424) | def predict_dataloader(self) -> DataLoader: FILE: threestudio/data/random_multiview.py class RandomMultiviewCameraDataModuleConfig (line 32) | class RandomMultiviewCameraDataModuleConfig(RandomCameraDataModuleConfig): class RandomMultiviewCameraIterableDataset (line 37) | class RandomMultiviewCameraIterableDataset(RandomCameraIterableDataset): method __init__ (line 39) | def __init__(self, *args, **kwargs): method collate (line 43) | def collate(self, batch) -> Dict[str, Any]: class RandomMultiviewCameraDataModule (line 293) | class RandomMultiviewCameraDataModule(pl.LightningDataModule): method __init__ (line 296) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 300) | def setup(self, stage=None) -> None: method prepare_data (line 308) | def prepare_data(self): method general_loader (line 311) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 321) | def train_dataloader(self) -> DataLoader: method val_dataloader (line 326) | def val_dataloader(self) -> DataLoader: method test_dataloader (line 332) | def test_dataloader(self) -> DataLoader: method predict_dataloader (line 337) | def predict_dataloader(self) -> DataLoader: FILE: threestudio/data/single_multiview_combined.py class RandomSingleMultiViewCameraIterableDataset (line 27) | class RandomSingleMultiViewCameraIterableDataset(IterableDataset, Update... method __init__ (line 28) | def __init__(self, cfg_single_view: Any, cfg_multi_view: Any, multi_ra... method update_step (line 38) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method __iter__ (line 42) | def __iter__(self): method collate (line 46) | def collate(self, batch) -> Dict[str, Any]: class SingleMultiviewCombinedCameraDataModule (line 65) | class SingleMultiviewCombinedCameraDataModule(pl.LightningDataModule): method __init__ (line 68) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 74) | def setup(self, stage=None) -> None: method prepare_data (line 82) | def prepare_data(self): method general_loader (line 85) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 95) | def train_dataloader(self) -> DataLoader: method val_dataloader (line 100) | def val_dataloader(self) -> DataLoader: method test_dataloader (line 105) | def test_dataloader(self) -> DataLoader: method predict_dataloader (line 110) | def predict_dataloader(self) -> DataLoader: FILE: threestudio/data/uncond.py class RandomCameraDataModuleConfig (line 26) | class RandomCameraDataModuleConfig: class RandomCameraIterableDataset (line 84) | class RandomCameraIterableDataset(IterableDataset, Updateable): method __init__ (line 85) | def __init__(self, cfg: Any) -> None: method update_step (line 163) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method __iter__ (line 175) | def __iter__(self): method collate (line 179) | def collate(self, batch) -> Dict[str, Any]: class RandomCameraDataset (line 477) | class RandomCameraDataset(Dataset): method __init__ (line 478) | def __init__(self, cfg: Any, split: str) -> None: method __len__ (line 630) | def __len__(self): method __getitem__ (line 633) | def __getitem__(self, index): method collate (line 653) | def collate(self, batch): class RandomCameraDataModule (line 660) | class RandomCameraDataModule(pl.LightningDataModule): method __init__ (line 663) | def __init__(self, cfg: Optional[Union[dict, DictConfig]] = None) -> N... method setup (line 667) | def setup(self, stage=None) -> None: method prepare_data (line 675) | def prepare_data(self): method general_loader (line 678) | def general_loader(self, dataset, batch_size, collate_fn=None) -> Data... method train_dataloader (line 688) | def train_dataloader(self) -> DataLoader: method val_dataloader (line 693) | def val_dataloader(self) -> DataLoader: method test_dataloader (line 699) | def test_dataloader(self) -> DataLoader: method predict_dataloader (line 704) | def predict_dataloader(self) -> DataLoader: FILE: threestudio/models/background/base.py class BaseBackground (line 13) | class BaseBackground(BaseModule): class Config (line 15) | class Config(BaseModule.Config): method configure (line 20) | def configure(self): method forward (line 23) | def forward(self, dirs: Float[Tensor, "*B 3"]) -> Float[Tensor, "*B 3"]: FILE: threestudio/models/background/neural_environment_map_background.py class NeuralEnvironmentMapBackground (line 16) | class NeuralEnvironmentMapBackground(BaseBackground): class Config (line 18) | class Config(BaseBackground.Config): method configure (line 38) | def configure(self) -> None: method forward (line 46) | def forward(self, dirs: Float[Tensor, "*B 3"]) -> Float[Tensor, "*B 3"]: FILE: threestudio/models/background/solid_color_background.py class SolidColorBackground (line 13) | class SolidColorBackground(BaseBackground): class Config (line 15) | class Config(BaseBackground.Config): method configure (line 22) | def configure(self) -> None: method forward (line 33) | def forward(self, dirs: Float[Tensor, "*B 3"]) -> Float[Tensor, "*B Nc"]: FILE: threestudio/models/background/textured_background.py class TexturedBackground (line 14) | class TexturedBackground(BaseBackground): class Config (line 16) | class Config(BaseBackground.Config): method configure (line 24) | def configure(self) -> None: method spherical_xyz_to_uv (line 29) | def spherical_xyz_to_uv(self, dirs: Float[Tensor, "*B 3"]) -> Float[Te... method forward (line 37) | def forward(self, dirs: Float[Tensor, "*B 3"]) -> Float[Tensor, "*B Nc"]: FILE: threestudio/models/estimators.py class ImportanceEstimator (line 16) | class ImportanceEstimator(AbstractEstimator): method __init__ (line 17) | def __init__( method sampling (line 23) | def sampling( function _transform_stot (line 104) | def _transform_stot( FILE: threestudio/models/exporters/base.py class ExporterOutput (line 12) | class ExporterOutput: class Exporter (line 18) | class Exporter(BaseObject): class Config (line 20) | class Config(BaseObject.Config): method configure (line 25) | def configure( method geometry (line 40) | def geometry(self) -> BaseImplicitGeometry: method material (line 44) | def material(self) -> BaseMaterial: method background (line 48) | def background(self) -> BaseBackground: method __call__ (line 51) | def __call__(self, *args, **kwargs) -> List[ExporterOutput]: FILE: threestudio/models/exporters/mesh_exporter.py class MeshExporter (line 18) | class MeshExporter(Exporter): class Config (line 20) | class Config(Exporter.Config): method configure (line 34) | def configure( method __call__ (line 43) | def __call__(self) -> List[ExporterOutput]: method export_obj_with_mtl (line 53) | def export_obj_with_mtl(self, mesh: Mesh) -> List[ExporterOutput]: method export_obj (line 132) | def export_obj(self, mesh: Mesh) -> List[ExporterOutput]: FILE: threestudio/models/geometry/base.py function contract_to_unisphere (line 20) | def contract_to_unisphere( class BaseGeometry (line 35) | class BaseGeometry(BaseModule): class Config (line 37) | class Config(BaseModule.Config): method create_from (line 43) | def create_from( method export (line 50) | def export(self, *args, **kwargs) -> Dict[str, Any]: class BaseImplicitGeometry (line 54) | class BaseImplicitGeometry(BaseGeometry): class Config (line 56) | class Config(BaseGeometry.Config): method configure (line 70) | def configure(self) -> None: method _initilize_isosurface_helper (line 85) | def _initilize_isosurface_helper(self): method forward (line 101) | def forward( method forward_field (line 106) | def forward_field( method forward_level (line 113) | def forward_level( method _isosurface (line 119) | def _isosurface(self, bbox: Float[Tensor, "2 3"], fine_stage: bool = F... method isosurface (line 171) | def isosurface(self) -> Mesh: class BaseExplicitGeometry (line 191) | class BaseExplicitGeometry(BaseGeometry): class Config (line 193) | class Config(BaseGeometry.Config): method configure (line 198) | def configure(self) -> None: FILE: threestudio/models/geometry/implicit_sdf.py class ImplicitSDF (line 18) | class ImplicitSDF(BaseImplicitGeometry): class Config (line 20) | class Config(BaseImplicitGeometry.Config): method configure (line 59) | def configure(self) -> None: method initialize_shape (line 87) | def initialize_shape(self) -> None: method get_shifted_sdf (line 208) | def get_shifted_sdf( method forward (line 231) | def forward( method forward_sdf (line 279) | def forward_sdf(self, points: Float[Tensor, "*N Di"]) -> Float[Tensor,... method forward_field (line 289) | def forward_field( method forward_level (line 302) | def forward_level( method export (line 307) | def export(self, points: Float[Tensor, "*N Di"], **kwargs) -> Dict[str... FILE: threestudio/models/geometry/implicit_volume.py class ImplicitVolume (line 21) | class ImplicitVolume(BaseImplicitGeometry): class Config (line 23) | class Config(BaseImplicitGeometry.Config): method configure (line 61) | def configure(self) -> None: method set_density_grid (line 83) | def set_density_grid(self): method get_activated_density (line 102) | def get_activated_density( method forward (line 131) | def forward( method forward_density (line 206) | def forward_density(self, points: Float[Tensor, "*N Di"]) -> Float[Ten... method forward_field (line 217) | def forward_field( method forward_level (line 227) | def forward_level( method export (line 232) | def export(self, points: Float[Tensor, "*N Di"], **kwargs) -> Dict[str... method create_from (line 251) | def create_from( method update_step (line 282) | def update_step( FILE: threestudio/models/geometry/tetrahedra_sdf_grid.py class TetrahedraSDFGrid (line 24) | class TetrahedraSDFGrid(BaseExplicitGeometry): class Config (line 26) | class Config(BaseExplicitGeometry.Config): method configure (line 61) | def configure(self) -> None: method initialize_shape (line 123) | def initialize_shape(self) -> None: method isosurface (line 126) | def isosurface(self) -> Mesh: method forward (line 139) | def forward( method create_from (line 157) | def create_from( method export (line 243) | def export(self, points: Float[Tensor, "*N Di"], **kwargs) -> Dict[str... FILE: threestudio/models/geometry/volume_grid.py class VolumeGrid (line 15) | class VolumeGrid(BaseImplicitGeometry): class Config (line 17) | class Config(BaseImplicitGeometry.Config): method configure (line 33) | def configure(self) -> None: method get_density_bias (line 48) | def get_density_bias(self, points: Float[Tensor, "*N Di"]): method get_trilinear_feature (line 65) | def get_trilinear_feature( method forward (line 77) | def forward( method forward_density (line 133) | def forward_density(self, points: Float[Tensor, "*N Di"]) -> Float[Ten... method forward_field (line 147) | def forward_field( method forward_level (line 157) | def forward_level( method export (line 162) | def export(self, points: Float[Tensor, "*N Di"], **kwargs) -> Dict[str... FILE: threestudio/models/guidance/deep_floyd_guidance.py class DeepFloydGuidance (line 17) | class DeepFloydGuidance(BaseObject): class Config (line 19) | class Config(BaseObject.Config): method configure (line 41) | def configure(self) -> None: method forward_unet (line 104) | def forward_unet( method __call__ (line 117) | def __call__( method update_step (line 210) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/deep_floyd_vsd_guidance.py class ToWeightsDType (line 29) | class ToWeightsDType(nn.Module): method __init__ (line 30) | def __init__(self, module: nn.Module, dtype: torch.dtype): method forward (line 35) | def forward(self, x: Float[Tensor, "..."]) -> Float[Tensor, "..."]: class DeepFloydVSDGuidance (line 40) | class DeepFloydVSDGuidance(BaseModule): class Config (line 42) | class Config(BaseModule.Config): method configure (line 65) | def configure(self) -> None: method pipe (line 240) | def pipe(self): method pipe_lora (line 244) | def pipe_lora(self): method unet (line 248) | def unet(self): method unet_lora (line 252) | def unet_lora(self): method _sample (line 257) | def _sample( method sample (line 330) | def sample( method sample_lora (line 359) | def sample_lora( method forward_unet (line 406) | def forward_unet( method disable_unet_class_embedding (line 425) | def disable_unet_class_embedding(self, unet: UNet2DConditionModel): method compute_grad_vsd (line 433) | def compute_grad_vsd( method train_lora (line 526) | def train_lora( method forward (line 572) | def forward( method update_step (line 634) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/multiview_diffusion_guidance.py class MultiviewDiffusionGuidance (line 22) | class MultiviewDiffusionGuidance(BaseModule): class Config (line 24) | class Config(BaseModule.Config): method configure (line 46) | def configure(self) -> None: method get_camera_cond (line 64) | def get_camera_cond(self, method encode_images (line 77) | def encode_images( method forward (line 84) | def forward( method update_step (line 187) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/stable_diffusion_guidance.py class StableDiffusionGuidance (line 17) | class StableDiffusionGuidance(BaseObject): class Config (line 19) | class Config(BaseObject.Config): method configure (line 47) | def configure(self) -> None: method forward_unet (line 137) | def forward_unet( method encode_images (line 151) | def encode_images( method decode_latents (line 161) | def decode_latents( method compute_grad_sds (line 176) | def compute_grad_sds( method compute_grad_sjc (line 216) | def compute_grad_sjc( method __call__ (line 256) | def __call__( method update_step (line 315) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/stable_diffusion_vsd_guidance.py class ToWeightsDType (line 26) | class ToWeightsDType(nn.Module): method __init__ (line 27) | def __init__(self, module: nn.Module, dtype: torch.dtype): method forward (line 32) | def forward(self, x: Float[Tensor, "..."]) -> Float[Tensor, "..."]: class StableDiffusionVSDGuidance (line 37) | class StableDiffusionVSDGuidance(BaseModule): class Config (line 39) | class Config(BaseModule.Config): method configure (line 62) | def configure(self) -> None: method pipe (line 222) | def pipe(self): method pipe_lora (line 226) | def pipe_lora(self): method unet (line 230) | def unet(self): method unet_lora (line 234) | def unet_lora(self): method vae (line 238) | def vae(self): method vae_lora (line 242) | def vae_lora(self): method _sample (line 247) | def _sample( method sample (line 321) | def sample( method sample_lora (line 350) | def sample_lora( method forward_unet (line 397) | def forward_unet( method encode_images (line 416) | def encode_images( method decode_latents (line 426) | def decode_latents( method disable_unet_class_embedding (line 442) | def disable_unet_class_embedding(self, unet: UNet2DConditionModel): method compute_grad_vsd (line 450) | def compute_grad_vsd( method train_lora (line 553) | def train_lora( method get_latents (line 619) | def get_latents( method forward (line 634) | def forward( method update_step (line 692) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/svd_guidance.py class StableVideoDiffusionGuidance (line 27) | class StableVideoDiffusionGuidance(BaseObject): class Config (line 29) | class Config(BaseObject.Config): method configure (line 58) | def configure(self) -> None: method encode_image (line 84) | def encode_image(self, image): method embed_image (line 124) | def embed_image(self, image, num_videos_per_prompt=1, do_classifier_fr... method __call__ (line 161) | def __call__( method _resize_with_antialiasing (line 224) | def _resize_with_antialiasing(self, input, size, interpolation="bicubi... method _compute_padding (line 252) | def _compute_padding(self, kernel_size): method _filter2d (line 275) | def _filter2d(self, input, kernel): method _gaussian (line 298) | def _gaussian(self, window_size: int, sigma): method _gaussian_blur2d (line 314) | def _gaussian_blur2d(self, input, kernel_size, sigma): FILE: threestudio/models/guidance/video_stable_diffusion_guidance.py function tensor2vid (line 23) | def tensor2vid(video: torch.Tensor, mean=[0.5, 0.5, 0.5], std=[0.5, 0.5,... class StableDiffusionGuidance (line 41) | class StableDiffusionGuidance(BaseObject): class Config (line 43) | class Config(BaseObject.Config): method configure (line 71) | def configure(self) -> None: method forward_unet (line 176) | def forward_unet( method encode_images (line 190) | def encode_images( method decode_latents (line 249) | def decode_latents(self, latents): method compute_grad_sds (line 273) | def compute_grad_sds( method compute_grad_sjc (line 322) | def compute_grad_sjc( method get_text_embeddings (line 363) | def get_text_embeddings( method __call__ (line 514) | def __call__( method update_step (line 580) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method _encode_prompt (line 597) | def _encode_prompt( method gen_video (line 751) | def gen_video( method prepare_latents (line 956) | def prepare_latents( method prepare_extra_step_kwargs (line 982) | def prepare_extra_step_kwargs(self, generator, eta): method progress_bar (line 999) | def progress_bar(self, iterable=None, total=None): FILE: threestudio/models/guidance/video_stable_diffusion_vsd_guidance.py function tensor2vid (line 33) | def tensor2vid(video: torch.Tensor, mean=[0.5, 0.5, 0.5], std=[0.5, 0.5,... class ToWeightsDType (line 51) | class ToWeightsDType(nn.Module): method __init__ (line 52) | def __init__(self, module: nn.Module, dtype: torch.dtype): method forward (line 57) | def forward(self, x: Float[Tensor, "..."]) -> Float[Tensor, "..."]: class StableDiffusionVSDGuidance (line 62) | class StableDiffusionVSDGuidance(BaseModule): class Config (line 64) | class Config(BaseModule.Config): method configure (line 87) | def configure(self) -> None: method pipe (line 268) | def pipe(self): method pipe_lora (line 272) | def pipe_lora(self): method unet (line 276) | def unet(self): method unet_lora (line 280) | def unet_lora(self): method vae (line 284) | def vae(self): method vae_lora (line 288) | def vae_lora(self): method _sample (line 293) | def _sample( method sample (line 367) | def sample( method sample_lora (line 396) | def sample_lora( method forward_unet (line 443) | def forward_unet( method encode_images (line 472) | def encode_images( method decode_latents (line 516) | def decode_latents(self, latents): method get_text_embeddings (line 541) | def get_text_embeddings( method disable_unet_class_embedding (line 689) | def disable_unet_class_embedding(self, unet: UNet2DConditionModel): method compute_grad_vsd (line 697) | def compute_grad_vsd( method train_lora (line 784) | def train_lora( method get_latents (line 829) | def get_latents( method forward (line 845) | def forward( method update_step (line 900) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/videocrafter/gradio_app.py function videocrafter_demo (line 17) | def videocrafter_demo(result_dir='./tmp/'): FILE: threestudio/models/guidance/videocrafter/lvdm/basics.py function disabled_train (line 14) | def disabled_train(self, mode=True): function zero_module (line 19) | def zero_module(module): function scale_module (line 27) | def scale_module(module, scale): function conv_nd (line 36) | def conv_nd(dims, *args, **kwargs): function linear (line 49) | def linear(*args, **kwargs): function avg_pool_nd (line 56) | def avg_pool_nd(dims, *args, **kwargs): function nonlinearity (line 69) | def nonlinearity(type='silu'): class GroupNormSpecific (line 76) | class GroupNormSpecific(nn.GroupNorm): method forward (line 77) | def forward(self, x): function normalization (line 81) | def normalization(channels, num_groups=32): class HybridConditioner (line 90) | class HybridConditioner(nn.Module): method __init__ (line 92) | def __init__(self, c_concat_config, c_crossattn_config): method forward (line 97) | def forward(self, c_concat, c_crossattn): FILE: threestudio/models/guidance/videocrafter/lvdm/common.py function gather_data (line 8) | def gather_data(data, return_np=True): function autocast (line 16) | def autocast(f): function extract_into_tensor (line 25) | def extract_into_tensor(a, t, x_shape): function noise_like (line 31) | def noise_like(shape, device, repeat=False): function default (line 37) | def default(val, d): function exists (line 42) | def exists(val): function identity (line 45) | def identity(*args, **kwargs): function uniq (line 48) | def uniq(arr): function mean_flat (line 51) | def mean_flat(tensor): function ismap (line 57) | def ismap(x): function isimage (line 62) | def isimage(x): function max_neg_value (line 67) | def max_neg_value(t): function shape_to_str (line 70) | def shape_to_str(x): function init_ (line 74) | def init_(tensor): function checkpoint (line 81) | def checkpoint(func, inputs, params, flag): FILE: threestudio/models/guidance/videocrafter/lvdm/distributions.py class AbstractDistribution (line 5) | class AbstractDistribution: method sample (line 6) | def sample(self): method mode (line 9) | def mode(self): class DiracDistribution (line 13) | class DiracDistribution(AbstractDistribution): method __init__ (line 14) | def __init__(self, value): method sample (line 17) | def sample(self): method mode (line 20) | def mode(self): class DiagonalGaussianDistribution (line 24) | class DiagonalGaussianDistribution(object): method __init__ (line 25) | def __init__(self, parameters, deterministic=False): method sample (line 35) | def sample(self, noise=None): method kl (line 42) | def kl(self, other=None): method nll (line 56) | def nll(self, sample, dims=[1,2,3]): method mode (line 64) | def mode(self): function normal_kl (line 68) | def normal_kl(mean1, logvar1, mean2, logvar2): FILE: threestudio/models/guidance/videocrafter/lvdm/ema.py class LitEma (line 5) | class LitEma(nn.Module): method __init__ (line 6) | def __init__(self, model, decay=0.9999, use_num_upates=True): method forward (line 25) | def forward(self,model): method copy_to (line 46) | def copy_to(self, model): method store (line 55) | def store(self, parameters): method restore (line 64) | def restore(self, parameters): FILE: threestudio/models/guidance/videocrafter/lvdm/models/autoencoder.py class AutoencoderKL (line 13) | class AutoencoderKL(pl.LightningModule): method __init__ (line 14) | def __init__(self, method init_test (line 51) | def init_test(self,): method init_from_ckpt (line 80) | def init_from_ckpt(self, path, ignore_keys=list()): method encode (line 97) | def encode(self, x, **kwargs): method decode (line 104) | def decode(self, z, **kwargs): method forward (line 109) | def forward(self, input, sample_posterior=True): method get_input (line 118) | def get_input(self, batch, k): method training_step (line 128) | def training_step(self, batch, batch_idx, optimizer_idx): method validation_step (line 149) | def validation_step(self, batch, batch_idx): method configure_optimizers (line 163) | def configure_optimizers(self): method get_last_layer (line 174) | def get_last_layer(self): method log_images (line 178) | def log_images(self, batch, only_inputs=False, **kwargs): method to_rgb (line 194) | def to_rgb(self, x): class IdentityFirstStage (line 202) | class IdentityFirstStage(torch.nn.Module): method __init__ (line 203) | def __init__(self, *args, vq_interface=False, **kwargs): method encode (line 207) | def encode(self, x, *args, **kwargs): method decode (line 210) | def decode(self, x, *args, **kwargs): method quantize (line 213) | def quantize(self, x, *args, **kwargs): method forward (line 218) | def forward(self, x, *args, **kwargs): FILE: threestudio/models/guidance/videocrafter/lvdm/models/ddpm3d.py class DDPM (line 38) | class DDPM(pl.LightningModule): method __init__ (line 40) | def __init__(self, method register_schedule (line 113) | def register_schedule(self, given_betas=None, beta_schedule="linear", ... method ema_scope (line 168) | def ema_scope(self, context=None): method init_from_ckpt (line 182) | def init_from_ckpt(self, path, ignore_keys=list(), only_model=False): method q_mean_variance (line 200) | def q_mean_variance(self, x_start, t): method predict_start_from_noise (line 212) | def predict_start_from_noise(self, x_t, t, noise): method q_posterior (line 218) | def q_posterior(self, x_start, x_t, t): method p_mean_variance (line 227) | def p_mean_variance(self, x, t, clip_denoised: bool): method p_sample (line 240) | def p_sample(self, x, t, clip_denoised=True, repeat_noise=False): method p_sample_loop (line 249) | def p_sample_loop(self, shape, return_intermediates=False): method sample (line 264) | def sample(self, batch_size=16, return_intermediates=False): method q_sample (line 270) | def q_sample(self, x_start, t, noise=None): method get_input (line 276) | def get_input(self, batch, k): method _get_rows_from_list (line 281) | def _get_rows_from_list(self, samples): method log_images (line 289) | def log_images(self, batch, N=8, n_row=2, sample=True, return_keys=Non... class LatentDiffusion (line 327) | class LatentDiffusion(DDPM): method __init__ (line 329) | def __init__(self, method make_cond_schedule (line 407) | def make_cond_schedule(self, ): method q_sample (line 412) | def q_sample(self, x_start, t, noise=None): method _freeze_model (line 423) | def _freeze_model(self): method instantiate_first_stage (line 427) | def instantiate_first_stage(self, config): method instantiate_cond_stage (line 434) | def instantiate_cond_stage(self, config): method get_learned_conditioning (line 445) | def get_learned_conditioning(self, c): method get_first_stage_encoding (line 458) | def get_first_stage_encoding(self, encoder_posterior, noise=None): method encode_first_stage (line 468) | def encode_first_stage(self, x): method encode_first_stage_2DAE (line 485) | def encode_first_stage_2DAE(self, x): method decode_core (line 492) | def decode_core(self, z, **kwargs): method decode_first_stage (line 509) | def decode_first_stage(self, z, **kwargs): method apply_model (line 512) | def apply_model(self, x_noisy, t, cond, **kwargs): method _get_denoise_row_from_list (line 528) | def _get_denoise_row_from_list(self, samples, desc=''): method decode_first_stage_2DAE (line 555) | def decode_first_stage_2DAE(self, z, **kwargs): method p_mean_variance (line 564) | def p_mean_variance(self, x, c, t, clip_denoised: bool, return_x0=Fals... method p_sample (line 590) | def p_sample(self, x, c, t, clip_denoised=False, repeat_noise=False, r... method p_sample_loop (line 612) | def p_sample_loop(self, cond, shape, return_intermediates=False, x_T=N... class LatentVisualDiffusion (line 659) | class LatentVisualDiffusion(LatentDiffusion): method __init__ (line 660) | def __init__(self, cond_img_config, finegrained=False, random_cond=Fal... method instantiate_img_embedder (line 668) | def instantiate_img_embedder(self, config, freeze=True): method init_projector (line 676) | def init_projector(self, use_finegrained, num_tokens, input_dim, cross... method get_image_embeds (line 688) | def get_image_embeds(self, batch_imgs): class DiffusionWrapper (line 695) | class DiffusionWrapper(pl.LightningModule): method __init__ (line 696) | def __init__(self, diff_model_config, conditioning_key): method forward (line 701) | def forward(self, x, t, c_concat: list = None, c_crossattn: list = None, FILE: threestudio/models/guidance/videocrafter/lvdm/models/samplers/ddim.py class DDIMSampler (line 8) | class DDIMSampler(object): method __init__ (line 9) | def __init__(self, model, schedule="linear", **kwargs): method register_buffer (line 16) | def register_buffer(self, name, attr): method make_schedule (line 22) | def make_schedule(self, ddim_num_steps, ddim_discretize="uniform", ddi... method sample (line 63) | def sample(self, method ddim_sampling (line 132) | def ddim_sampling(self, cond, shape, method p_sample_ddim (line 212) | def p_sample_ddim(self, x, c, t, index, repeat_noise=False, use_origin... method stochastic_encode (line 294) | def stochastic_encode(self, x0, t, use_original_steps=False, noise=None): method decode (line 316) | def decode(self, x_latent, cond, t_start, unconditional_guidance_scale... FILE: threestudio/models/guidance/videocrafter/lvdm/models/utils_diffusion.py function timestep_embedding (line 8) | def timestep_embedding(timesteps, dim, max_period=10000, repeat_only=Fal... function make_beta_schedule (line 31) | def make_beta_schedule(schedule, n_timestep, linear_start=1e-4, linear_e... function make_ddim_timesteps (line 56) | def make_ddim_timesteps(ddim_discr_method, num_ddim_timesteps, num_ddpm_... function make_ddim_sampling_parameters (line 73) | def make_ddim_sampling_parameters(alphacums, ddim_timesteps, eta, verbos... function betas_for_alpha_bar (line 88) | def betas_for_alpha_bar(num_diffusion_timesteps, alpha_bar, max_beta=0.9... FILE: threestudio/models/guidance/videocrafter/lvdm/modules/attention.py class RelativePosition (line 21) | class RelativePosition(nn.Module): method __init__ (line 24) | def __init__(self, num_units, max_relative_position): method forward (line 31) | def forward(self, length_q, length_k): class CrossAttention (line 43) | class CrossAttention(nn.Module): method __init__ (line 45) | def __init__(self, query_dim, context_dim=None, heads=8, dim_head=64, ... method forward (line 76) | def forward(self, x, context=None, mask=None): method efficient_forward (line 129) | def efficient_forward(self, x, context=None, mask=None): class BasicTransformerBlock (line 187) | class BasicTransformerBlock(nn.Module): method __init__ (line 189) | def __init__(self, dim, n_heads, d_head, dropout=0., context_dim=None,... method forward (line 204) | def forward(self, x, context=None, mask=None): method _forward (line 216) | def _forward(self, x, context=None, mask=None): class SpatialTransformer (line 223) | class SpatialTransformer(nn.Module): method __init__ (line 233) | def __init__(self, in_channels, n_heads, d_head, depth=1, dropout=0., ... method forward (line 262) | def forward(self, x, context=None): class TemporalTransformer (line 281) | class TemporalTransformer(nn.Module): method __init__ (line 288) | def __init__(self, in_channels, n_heads, d_head, depth=1, dropout=0., ... method forward (line 331) | def forward(self, x, context=None): class GEGLU (line 376) | class GEGLU(nn.Module): method __init__ (line 377) | def __init__(self, dim_in, dim_out): method forward (line 381) | def forward(self, x): class FeedForward (line 386) | class FeedForward(nn.Module): method __init__ (line 387) | def __init__(self, dim, dim_out=None, mult=4, glu=False, dropout=0.): method forward (line 402) | def forward(self, x): class LinearAttention (line 406) | class LinearAttention(nn.Module): method __init__ (line 407) | def __init__(self, dim, heads=4, dim_head=32): method forward (line 414) | def forward(self, x): class SpatialSelfAttention (line 425) | class SpatialSelfAttention(nn.Module): method __init__ (line 426) | def __init__(self, in_channels): method forward (line 452) | def forward(self, x): FILE: threestudio/models/guidance/videocrafter/lvdm/modules/encoders/condition.py class AbstractEncoder (line 10) | class AbstractEncoder(nn.Module): method __init__ (line 11) | def __init__(self): method encode (line 14) | def encode(self, *args, **kwargs): class IdentityEncoder (line 18) | class IdentityEncoder(AbstractEncoder): method encode (line 20) | def encode(self, x): class ClassEmbedder (line 24) | class ClassEmbedder(nn.Module): method __init__ (line 25) | def __init__(self, embed_dim, n_classes=1000, key='class', ucg_rate=0.1): method forward (line 32) | def forward(self, batch, key=None, disable_dropout=False): method get_unconditional_conditioning (line 44) | def get_unconditional_conditioning(self, bs, device="cuda"): function disabled_train (line 51) | def disabled_train(self, mode=True): class FrozenT5Embedder (line 57) | class FrozenT5Embedder(AbstractEncoder): method __init__ (line 60) | def __init__(self, version="google/t5-v1_1-large", device="cuda", max_... method freeze (line 70) | def freeze(self): method forward (line 76) | def forward(self, text): method encode (line 85) | def encode(self, text): class FrozenCLIPEmbedder (line 89) | class FrozenCLIPEmbedder(AbstractEncoder): method __init__ (line 97) | def __init__(self, version="openai/clip-vit-large-patch14", device="cu... method freeze (line 113) | def freeze(self): method forward (line 119) | def forward(self, text): method encode (line 132) | def encode(self, text): class ClipImageEmbedder (line 136) | class ClipImageEmbedder(nn.Module): method __init__ (line 137) | def __init__( method preprocess (line 155) | def preprocess(self, x): method forward (line 165) | def forward(self, x, no_dropout=False): class FrozenOpenCLIPEmbedder (line 174) | class FrozenOpenCLIPEmbedder(AbstractEncoder): method __init__ (line 184) | def __init__(self, arch="ViT-H-14", version="laion2b_s32b_b79k", devic... method freeze (line 204) | def freeze(self): method forward (line 209) | def forward(self, text): method encode_with_transformer (line 215) | def encode_with_transformer(self, text): method text_transformer_forward (line 224) | def text_transformer_forward(self, x: torch.Tensor, attn_mask=None): method encode (line 234) | def encode(self, text): class FrozenOpenCLIPImageEmbedder (line 238) | class FrozenOpenCLIPImageEmbedder(AbstractEncoder): method __init__ (line 243) | def __init__(self, arch="ViT-H-14", version="laion2b_s32b_b79k", devic... method preprocess (line 266) | def preprocess(self, x): method freeze (line 276) | def freeze(self): method forward (line 282) | def forward(self, image, no_dropout=False): method encode_with_vision_transformer (line 288) | def encode_with_vision_transformer(self, img): method encode (line 293) | def encode(self, text): class FrozenOpenCLIPImageEmbedderV2 (line 298) | class FrozenOpenCLIPImageEmbedderV2(AbstractEncoder): method __init__ (line 303) | def __init__(self, arch="ViT-H-14", version="laion2b_s32b_b79k", devic... method preprocess (line 324) | def preprocess(self, x): method freeze (line 334) | def freeze(self): method forward (line 339) | def forward(self, image, no_dropout=False): method encode_with_vision_transformer (line 344) | def encode_with_vision_transformer(self, x): class FrozenCLIPT5Encoder (line 377) | class FrozenCLIPT5Encoder(AbstractEncoder): method __init__ (line 378) | def __init__(self, clip_version="openai/clip-vit-large-patch14", t5_ve... method encode (line 386) | def encode(self, text): method forward (line 389) | def forward(self, text): FILE: threestudio/models/guidance/videocrafter/lvdm/modules/encoders/ip_resampler.py class ImageProjModel (line 7) | class ImageProjModel(nn.Module): method __init__ (line 9) | def __init__(self, cross_attention_dim=1024, clip_embeddings_dim=1024,... method forward (line 16) | def forward(self, image_embeds): function FeedForward (line 24) | def FeedForward(dim, mult=4): function reshape_tensor (line 34) | def reshape_tensor(x, heads): class PerceiverAttention (line 45) | class PerceiverAttention(nn.Module): method __init__ (line 46) | def __init__(self, *, dim, dim_head=64, heads=8): method forward (line 61) | def forward(self, x, latents): class Resampler (line 93) | class Resampler(nn.Module): method __init__ (line 94) | def __init__( method forward (line 125) | def forward(self, x): FILE: threestudio/models/guidance/videocrafter/lvdm/modules/networks/ae_modules.py function nonlinearity (line 10) | def nonlinearity(x): function Normalize (line 15) | def Normalize(in_channels, num_groups=32): class LinAttnBlock (line 20) | class LinAttnBlock(LinearAttention): method __init__ (line 22) | def __init__(self, in_channels): class AttnBlock (line 26) | class AttnBlock(nn.Module): method __init__ (line 27) | def __init__(self, in_channels): method forward (line 53) | def forward(self, x): function make_attn (line 80) | def make_attn(in_channels, attn_type="vanilla"): class Downsample (line 90) | class Downsample(nn.Module): method __init__ (line 91) | def __init__(self, in_channels, with_conv): method forward (line 102) | def forward(self, x): class Upsample (line 111) | class Upsample(nn.Module): method __init__ (line 112) | def __init__(self, in_channels, with_conv): method forward (line 123) | def forward(self, x): function get_timestep_embedding (line 129) | def get_timestep_embedding(timesteps, embedding_dim): class ResnetBlock (line 151) | class ResnetBlock(nn.Module): method __init__ (line 152) | def __init__(self, *, in_channels, out_channels=None, conv_shortcut=Fa... method forward (line 190) | def forward(self, x, temb): class Model (line 212) | class Model(nn.Module): method __init__ (line 213) | def __init__(self, *, ch, out_ch, ch_mult=(1,2,4,8), num_res_blocks, method forward (line 312) | def forward(self, x, t=None, context=None): method get_last_layer (line 360) | def get_last_layer(self): class Encoder (line 364) | class Encoder(nn.Module): method __init__ (line 365) | def __init__(self, *, ch, out_ch, ch_mult=(1,2,4,8), num_res_blocks, method forward (line 430) | def forward(self, x): class Decoder (line 466) | class Decoder(nn.Module): method __init__ (line 467) | def __init__(self, *, ch, out_ch, ch_mult=(1,2,4,8), num_res_blocks, method forward (line 539) | def forward(self, z): class SimpleDecoder (line 581) | class SimpleDecoder(nn.Module): method __init__ (line 582) | def __init__(self, in_channels, out_channels, *args, **kwargs): method forward (line 604) | def forward(self, x): class UpsampleDecoder (line 617) | class UpsampleDecoder(nn.Module): method __init__ (line 618) | def __init__(self, in_channels, out_channels, ch, num_res_blocks, reso... method forward (line 651) | def forward(self, x): class LatentRescaler (line 665) | class LatentRescaler(nn.Module): method __init__ (line 666) | def __init__(self, factor, in_channels, mid_channels, out_channels, de... method forward (line 690) | def forward(self, x): class MergedRescaleEncoder (line 702) | class MergedRescaleEncoder(nn.Module): method __init__ (line 703) | def __init__(self, in_channels, ch, resolution, out_ch, num_res_blocks, method forward (line 715) | def forward(self, x): class MergedRescaleDecoder (line 721) | class MergedRescaleDecoder(nn.Module): method __init__ (line 722) | def __init__(self, z_channels, out_ch, resolution, num_res_blocks, att... method forward (line 732) | def forward(self, x): class Upsampler (line 738) | class Upsampler(nn.Module): method __init__ (line 739) | def __init__(self, in_size, out_size, in_channels, out_channels, ch_mu... method forward (line 751) | def forward(self, x): class Resize (line 757) | class Resize(nn.Module): method __init__ (line 758) | def __init__(self, in_channels=None, learned=False, mode="bilinear"): method forward (line 773) | def forward(self, x, scale_factor=1.0): class FirstStagePostProcessor (line 780) | class FirstStagePostProcessor(nn.Module): method __init__ (line 782) | def __init__(self, ch_mult:list, in_channels, method instantiate_pretrained (line 817) | def instantiate_pretrained(self, config): method encode_with_pretrained (line 826) | def encode_with_pretrained(self,x): method forward (line 832) | def forward(self,x): FILE: threestudio/models/guidance/videocrafter/lvdm/modules/networks/openaimodel3d.py class TimestepBlock (line 19) | class TimestepBlock(nn.Module): method forward (line 24) | def forward(self, x, emb): class TimestepEmbedSequential (line 30) | class TimestepEmbedSequential(nn.Sequential, TimestepBlock): method forward (line 36) | def forward(self, x, emb, context=None, batch_size=None): class Downsample (line 51) | class Downsample(nn.Module): method __init__ (line 60) | def __init__(self, channels, use_conv, dims=2, out_channels=None, padd... method forward (line 75) | def forward(self, x): class Upsample (line 80) | class Upsample(nn.Module): method __init__ (line 89) | def __init__(self, channels, use_conv, dims=2, out_channels=None, padd... method forward (line 98) | def forward(self, x): class ResBlock (line 109) | class ResBlock(TimestepBlock): method __init__ (line 124) | def __init__( method forward (line 195) | def forward(self, x, emb, batch_size=None): method _forward (line 208) | def _forward(self, x, emb, batch_size=None,): class TemporalConvBlock (line 237) | class TemporalConvBlock(nn.Module): method __init__ (line 242) | def __init__(self, in_channels, out_channels=None, dropout=0.0, spatia... method forward (line 269) | def forward(self, x): class UNetModel (line 279) | class UNetModel(nn.Module): method __init__ (line 307) | def __init__(self, method forward (line 534) | def forward(self, x, timesteps, context=None, features_adapter=None, f... FILE: threestudio/models/guidance/videocrafter/lvdm/modules/x_transformer.py class AbsolutePositionalEmbedding (line 24) | class AbsolutePositionalEmbedding(nn.Module): method __init__ (line 25) | def __init__(self, dim, max_seq_len): method init_ (line 30) | def init_(self): method forward (line 33) | def forward(self, x): class FixedPositionalEmbedding (line 38) | class FixedPositionalEmbedding(nn.Module): method __init__ (line 39) | def __init__(self, dim): method forward (line 44) | def forward(self, x, seq_dim=1, offset=0): function exists (line 53) | def exists(val): function default (line 57) | def default(val, d): function always (line 63) | def always(val): function not_equals (line 69) | def not_equals(val): function equals (line 75) | def equals(val): function max_neg_value (line 81) | def max_neg_value(tensor): function pick_and_pop (line 87) | def pick_and_pop(keys, d): function group_dict_by_key (line 92) | def group_dict_by_key(cond, d): function string_begins_with (line 101) | def string_begins_with(prefix, str): function group_by_key_prefix (line 105) | def group_by_key_prefix(prefix, d): function groupby_prefix_and_trim (line 109) | def groupby_prefix_and_trim(prefix, d): class Scale (line 116) | class Scale(nn.Module): method __init__ (line 117) | def __init__(self, value, fn): method forward (line 122) | def forward(self, x, **kwargs): class Rezero (line 127) | class Rezero(nn.Module): method __init__ (line 128) | def __init__(self, fn): method forward (line 133) | def forward(self, x, **kwargs): class ScaleNorm (line 138) | class ScaleNorm(nn.Module): method __init__ (line 139) | def __init__(self, dim, eps=1e-5): method forward (line 145) | def forward(self, x): class RMSNorm (line 150) | class RMSNorm(nn.Module): method __init__ (line 151) | def __init__(self, dim, eps=1e-8): method forward (line 157) | def forward(self, x): class Residual (line 162) | class Residual(nn.Module): method forward (line 163) | def forward(self, x, residual): class GRUGating (line 167) | class GRUGating(nn.Module): method __init__ (line 168) | def __init__(self, dim): method forward (line 172) | def forward(self, x, residual): class GEGLU (line 183) | class GEGLU(nn.Module): method __init__ (line 184) | def __init__(self, dim_in, dim_out): method forward (line 188) | def forward(self, x): class FeedForward (line 193) | class FeedForward(nn.Module): method __init__ (line 194) | def __init__(self, dim, dim_out=None, mult=4, glu=False, dropout=0.): method forward (line 209) | def forward(self, x): class Attention (line 214) | class Attention(nn.Module): method __init__ (line 215) | def __init__( method forward (line 267) | def forward( class AttentionLayers (line 369) | class AttentionLayers(nn.Module): method __init__ (line 370) | def __init__( method forward (line 480) | def forward( class Encoder (line 540) | class Encoder(AttentionLayers): method __init__ (line 541) | def __init__(self, **kwargs): class TransformerWrapper (line 547) | class TransformerWrapper(nn.Module): method __init__ (line 548) | def __init__( method init_ (line 594) | def init_(self): method forward (line 597) | def forward( FILE: threestudio/models/guidance/videocrafter/predict.py class Predictor (line 26) | class Predictor(BasePredictor): method setup (line 27) | def setup(self) -> None: method predict (line 49) | def predict( FILE: threestudio/models/guidance/videocrafter/scripts/evaluation/ddp_wrapper.py function setup_dist (line 8) | def setup_dist(local_rank): function get_dist_info (line 15) | def get_dist_info(): FILE: threestudio/models/guidance/videocrafter/scripts/evaluation/funcs.py function batch_ddim_sampling (line 15) | def batch_ddim_sampling(model, cond, noise_shape, n_samples=1, ddim_step... function get_filelist (line 73) | def get_filelist(data_dir, ext='*'): function get_dirlist (line 78) | def get_dirlist(path): function load_model_checkpoint (line 90) | def load_model_checkpoint(model, ckpt=None, model_info = {"repo_id": "Vi... function load_prompts (line 114) | def load_prompts(prompt_file): function load_video_batch (line 125) | def load_video_batch(filepath_list, frame_stride, video_size=(256,256), ... function load_image_batch (line 164) | def load_image_batch(filepath_list, image_size=(256,256)): function save_videos (line 188) | def save_videos(batch_tensors, savedir, filenames, fps=10): FILE: threestudio/models/guidance/videocrafter/scripts/evaluation/inference.py function get_parser (line 18) | def get_parser(): function run_inference (line 42) | def run_inference(args, gpu_num, gpu_no, **kwargs): FILE: threestudio/models/guidance/videocrafter/scripts/gradio/i2v_test.py class Image2Video (line 9) | class Image2Video(): method __init__ (line 10) | def __init__(self,result_dir='./tmp/',gpu_num=1) -> None: method get_image (line 31) | def get_image(self, image, prompt, steps=50, cfg_scale=12.0, eta=1.0, ... method download_model (line 70) | def download_model(self): FILE: threestudio/models/guidance/videocrafter/scripts/gradio/t2v_test.py class Text2Video (line 9) | class Text2Video(): method __init__ (line 10) | def __init__(self,result_dir='./tmp/',gpu_num=1) -> None: method get_prompt (line 31) | def get_prompt(self, prompt, steps=50, cfg_scale=12.0, eta=1.0, fps=16): method download_model (line 62) | def download_model(self): FILE: threestudio/models/guidance/videocrafter/utils/utils.py function count_params (line 8) | def count_params(model, verbose=False): function check_istarget (line 15) | def check_istarget(name, para_list): function instantiate_from_config (line 27) | def instantiate_from_config(config): function get_obj_from_str (line 37) | def get_obj_from_str(string, reload=False): function load_npz_from_dir (line 45) | def load_npz_from_dir(data_dir): function load_npz_from_paths (line 51) | def load_npz_from_paths(data_paths): function resize_numpy_image (line 57) | def resize_numpy_image(image, max_resolution=512 * 512, resize_short_edg... function setup_dist (line 70) | def setup_dist(args): FILE: threestudio/models/guidance/videocrafter_guidance.py class VideoCrafterGuidance (line 21) | class VideoCrafterGuidance(BaseObject): class Config (line 23) | class Config(BaseObject.Config): method configure (line 60) | def configure(self) -> None: method forward_unet (line 95) | def forward_unet( method encode_first_stage (line 108) | def encode_first_stage(self, x): method encode_images (line 156) | def encode_images( method decode_latents (line 184) | def decode_latents(self, latents): method add_noise (line 187) | def add_noise( method compute_grad_sds (line 210) | def compute_grad_sds( method __call__ (line 268) | def __call__( method update_step (line 323) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/guidance/zero123_guidance.py function get_obj_from_str (line 21) | def get_obj_from_str(string, reload=False): function instantiate_from_config (line 29) | def instantiate_from_config(config): function load_model_from_config (line 40) | def load_model_from_config(config, ckpt, device, vram_O=True, verbose=Fa... class Zero123Guidance (line 75) | class Zero123Guidance(BaseObject): class Config (line 77) | class Config(BaseObject.Config): method configure (line 99) | def configure(self) -> None: method set_min_max_steps (line 143) | def set_min_max_steps(self, min_step_percent=0.02, max_step_percent=0.... method prepare_embeddings (line 148) | def prepare_embeddings(self, image_path: str) -> Float[Tensor, "B 3 25... method get_img_embeds (line 172) | def get_img_embeds( method encode_images (line 182) | def encode_images( method decode_latents (line 193) | def decode_latents( method get_cond (line 204) | def get_cond( method __call__ (line 254) | def __call__( method guidance_eval (line 334) | def guidance_eval(self, cond, t_orig, latents, noise_pred): method update_step (line 398) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method generate (line 407) | def generate( method gen_from_cond (line 433) | def gen_from_cond( FILE: threestudio/models/guidance/zeroscope_guidance.py class ZeroscopeGuidance (line 22) | class ZeroscopeGuidance(BaseObject): class Config (line 24) | class Config(BaseObject.Config): method configure (line 58) | def configure(self) -> None: method forward_unet (line 170) | def forward_unet( method encode_images (line 184) | def encode_images( method decode_latents (line 248) | def decode_latents(self, latents): method compute_grad_sds (line 272) | def compute_grad_sds( method compute_grad_sjc (line 327) | def compute_grad_sjc( method __call__ (line 367) | def __call__( method update_step (line 425) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... FILE: threestudio/models/isosurface.py class IsosurfaceHelper (line 11) | class IsosurfaceHelper(nn.Module): method grid_vertices (line 15) | def grid_vertices(self) -> Float[Tensor, "N 3"]: class MarchingCubeCPUHelper (line 19) | class MarchingCubeCPUHelper(IsosurfaceHelper): method __init__ (line 20) | def __init__(self, resolution: int) -> None: method grid_vertices (line 33) | def grid_vertices(self) -> Float[Tensor, "N3 3"]: method forward (line 48) | def forward( class MarchingTetrahedraHelper (line 69) | class MarchingTetrahedraHelper(IsosurfaceHelper): method __init__ (line 70) | def __init__(self, resolution: int, tets_path: str): method normalize_grid_deformation (line 130) | def normalize_grid_deformation( method grid_vertices (line 140) | def grid_vertices(self) -> Float[Tensor, "Nv 3"]: method all_edges (line 144) | def all_edges(self) -> Integer[Tensor, "Ne 2"]: method sort_edges (line 158) | def sort_edges(self, edges_ex2): method _forward (line 168) | def _forward(self, pos_nx3, sdf_n, tet_fx4): method forward (line 229) | def forward( FILE: threestudio/models/materials/base.py class BaseMaterial (line 13) | class BaseMaterial(BaseModule): class Config (line 15) | class Config(BaseModule.Config): method configure (line 21) | def configure(self): method forward (line 24) | def forward(self, *args, **kwargs) -> Float[Tensor, "*B 3"]: method export (line 27) | def export(self, *args, **kwargs) -> Dict[str, Any]: FILE: threestudio/models/materials/diffuse_with_point_light_material.py class DiffuseWithPointLightMaterial (line 15) | class DiffuseWithPointLightMaterial(BaseMaterial): class Config (line 17) | class Config(BaseMaterial.Config): method configure (line 29) | def configure(self) -> None: method forward (line 42) | def forward( method update_step (line 109) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method export (line 115) | def export(self, features: Float[Tensor, "*N Nf"], **kwargs) -> Dict[s... FILE: threestudio/models/materials/neural_radiance_material.py class NeuralRadianceMaterial (line 16) | class NeuralRadianceMaterial(BaseMaterial): class Config (line 18) | class Config(BaseMaterial.Config): method configure (line 35) | def configure(self) -> None: method forward (line 40) | def forward( FILE: threestudio/models/materials/no_material.py class NoMaterial (line 16) | class NoMaterial(BaseMaterial): class Config (line 18) | class Config(BaseMaterial.Config): method configure (line 26) | def configure(self) -> None: method forward (line 39) | def forward( method export (line 54) | def export(self, features: Float[Tensor, "*N Nf"], **kwargs) -> Dict[s... FILE: threestudio/models/materials/sd_latent_adapter_material.py class StableDiffusionLatentAdapterMaterial (line 14) | class StableDiffusionLatentAdapterMaterial(BaseMaterial): class Config (line 16) | class Config(BaseMaterial.Config): method configure (line 21) | def configure(self) -> None: method forward (line 35) | def forward( FILE: threestudio/models/mesh.py class Mesh (line 12) | class Mesh: method __init__ (line 13) | def __init__( method add_extra (line 28) | def add_extra(self, k, v) -> None: method remove_outlier (line 31) | def remove_outlier(self, outlier_n_faces_threshold: Union[int, float])... method requires_grad (line 97) | def requires_grad(self): method v_nrm (line 101) | def v_nrm(self): method v_tng (line 107) | def v_tng(self): method v_tex (line 113) | def v_tex(self): method t_tex_idx (line 119) | def t_tex_idx(self): method v_rgb (line 125) | def v_rgb(self): method edges (line 129) | def edges(self): method _compute_vertex_normal (line 134) | def _compute_vertex_normal(self): method _compute_vertex_tangent (line 162) | def _compute_vertex_tangent(self): method _unwrap_uv (line 206) | def _unwrap_uv( method unwrap_uv (line 243) | def unwrap_uv( method set_vertex_color (line 250) | def set_vertex_color(self, v_rgb): method _compute_edges (line 254) | def _compute_edges(self): method normal_consistency (line 268) | def normal_consistency(self) -> Float[Tensor, ""]: method _laplacian_uniform (line 275) | def _laplacian_uniform(self): method laplacian (line 302) | def laplacian(self) -> Float[Tensor, ""]: FILE: threestudio/models/networks.py class ProgressiveBandFrequency (line 16) | class ProgressiveBandFrequency(nn.Module, Updateable): method __init__ (line 17) | def __init__(self, in_channels: int, config: dict): method forward (line 29) | def forward(self, x): method update_step (line 36) | def update_step(self, epoch, global_step, on_load_weights=False): class TCNNEncoding (line 55) | class TCNNEncoding(nn.Module): method __init__ (line 56) | def __init__(self, in_channels, config, dtype=torch.float32) -> None: method forward (line 63) | def forward(self, x): class PEEncoder (line 66) | class PEEncoder(nn.Module): method __init__ (line 68) | def __init__(self, x_dim=4, min_deg=0, max_deg=4, use_identity: bool =... method latent_dim (line 80) | def latent_dim(self) -> int: method forward (line 85) | def forward(self, x: torch.Tensor) -> torch.Tensor: class TCNNEncodingSpatialTimeDeform (line 98) | class TCNNEncodingSpatialTimeDeform(nn.Module): method __init__ (line 99) | def __init__(self, in_channels, config, dtype=torch.float32, init_time... method init_params_zero (line 135) | def init_params_zero(self, param_list): method set_temp_param_grad (line 142) | def set_temp_param_grad(self, requires_grad=False): method set_param_grad (line 147) | def set_param_grad(self, param_list, requires_grad=False): method warp (line 154) | def warp(self, x): method log1p_safe (line 157) | def log1p_safe(self, x): method exp_safe (line 161) | def exp_safe(self, x): method expm1_safe (line 164) | def expm1_safe(self, x): method safe_sqrt (line 167) | def safe_sqrt(x, eps=1e-7): method general_loss_with_squared_residual (line 171) | def general_loss_with_squared_residual(self, squared_x, alpha, scale): method elastic_loss (line 210) | def elastic_loss(self, x_frame_time, dx, alpha=-2.0, scale=0.03, delta... method divergence_loss (line 228) | def divergence_loss(self, x_frame_time, dx, delta = 1e-6, div_clamp = ... method forward (line 258) | def forward(self, x, grid, out_all=False): class ProgressiveBandHashGrid (line 310) | class ProgressiveBandHashGrid(nn.Module, Updateable): method __init__ (line 311) | def __init__(self, in_channels, config, dtype=torch.float32): method forward (line 334) | def forward(self, x): method update_step (line 339) | def update_step(self, epoch, global_step, on_load_weights=False): class CompositeEncoding (line 351) | class CompositeEncoding(nn.Module, Updateable): method __init__ (line 352) | def __init__(self, encoding, include_xyz=False, xyz_scale=1.0, xyz_off... method forward (line 365) | def forward(self, x, *args, **kwargs): function get_encoding (line 375) | def get_encoding(n_input_dims: int, config) -> nn.Module: class VanillaMLP (line 395) | class VanillaMLP(nn.Module): method __init__ (line 396) | def __init__(self, dim_in: int, dim_out: int, config: dict): method forward (line 419) | def forward(self, x): method make_linear (line 427) | def make_linear(self, dim_in, dim_out, is_first, is_last, bias=False): method make_activation (line 431) | def make_activation(self): class TCNNNetwork (line 435) | class TCNNNetwork(nn.Module): method __init__ (line 436) | def __init__(self, dim_in: int, dim_out: int, config: dict) -> None: method forward (line 441) | def forward(self, x): function get_mlp (line 445) | def get_mlp(n_input_dims, n_output_dims, config) -> nn.Module: class NetworkWithInputEncoding (line 457) | class NetworkWithInputEncoding(nn.Module, Updateable): method __init__ (line 458) | def __init__(self, encoding, network): method forward (line 462) | def forward(self, x): class TCNNNetworkWithInputEncoding (line 466) | class TCNNNetworkWithInputEncoding(nn.Module): method __init__ (line 467) | def __init__( method forward (line 483) | def forward(self, x): function create_network_with_input_encoding (line 487) | def create_network_with_input_encoding( FILE: threestudio/models/prompt_processors/base.py function hash_prompt (line 16) | def hash_prompt(model: str, prompt: str) -> str: class DirectionConfig (line 24) | class DirectionConfig: class PromptProcessorOutput (line 35) | class PromptProcessorOutput: method get_text_embeddings (line 43) | def get_text_embeddings( function shift_azimuth_deg (line 73) | def shift_azimuth_deg(azimuth: Float[Tensor, "..."]) -> Float[Tensor, ".... class PromptProcessor (line 78) | class PromptProcessor(BaseObject): class Config (line 80) | class Config(BaseObject.Config): method configure_text_encoder (line 95) | def configure_text_encoder(self) -> None: method destroy_text_encoder (line 99) | def destroy_text_encoder(self) -> None: method configure (line 102) | def configure(self) -> None: method spawn_func (line 194) | def spawn_func(pretrained_model_name_or_path, prompts, cache_dir, cfg): method prepare_text_embeddings (line 198) | def prepare_text_embeddings(self): method load_text_embeddings (line 246) | def load_text_embeddings(self): method load_from_cache (line 261) | def load_from_cache(self, prompt): method preprocess_prompt (line 272) | def preprocess_prompt(self, prompt: str) -> str: method get_text_embeddings (line 293) | def get_text_embeddings( method __call__ (line 298) | def __call__(self) -> PromptProcessorOutput: FILE: threestudio/models/prompt_processors/deepfloyd_prompt_processor.py class DeepFloydPromptProcessor (line 17) | class DeepFloydPromptProcessor(PromptProcessor): class Config (line 19) | class Config(PromptProcessor.Config): method configure_text_encoder (line 25) | def configure_text_encoder(self) -> None: method destroy_text_encoder (line 40) | def destroy_text_encoder(self) -> None: method get_text_embeddings (line 45) | def get_text_embeddings( method spawn_func (line 56) | def spawn_func(pretrained_model_name_or_path, prompts, cache_dir, cfg): FILE: threestudio/models/prompt_processors/stable_diffusion_prompt_processor.py class StableDiffusionPromptProcessor (line 16) | class StableDiffusionPromptProcessor(PromptProcessor): class Config (line 18) | class Config(PromptProcessor.Config): method configure_text_encoder (line 24) | def configure_text_encoder(self) -> None: method destroy_text_encoder (line 36) | def destroy_text_encoder(self) -> None: method get_text_embeddings (line 41) | def get_text_embeddings( method spawn_func (line 73) | def spawn_func(pretrained_model_name_or_path, prompts, cache_dir, cfg): FILE: threestudio/models/prompt_processors/videocrafter_prompt_processor.py class VideoCrafterPromptProcessor (line 23) | class VideoCrafterPromptProcessor(PromptProcessor): class Config (line 25) | class Config(PromptProcessor.Config): method configure_text_encoder (line 31) | def configure_text_encoder(self) -> None: method destroy_text_encoder (line 43) | def destroy_text_encoder(self) -> None: method get_text_embeddings (line 48) | def get_text_embeddings( method spawn_func (line 79) | def spawn_func(pretrained_model_name_or_path, prompts, cache_dir, cfg): FILE: threestudio/models/prompt_processors/zero123_prompt_processor.py class Zero123PromptProcessor (line 12) | class Zero123PromptProcessor(PromptProcessor): class Config (line 14) | class Config(PromptProcessor.Config): FILE: threestudio/models/prompt_processors/zeroscope_diffusion_prompt_processor.py class ZeroScopeDiffusionPromptProcessor (line 16) | class ZeroScopeDiffusionPromptProcessor(PromptProcessor): class Config (line 18) | class Config(PromptProcessor.Config): method configure_text_encoder (line 24) | def configure_text_encoder(self) -> None: method destroy_text_encoder (line 36) | def destroy_text_encoder(self) -> None: method get_text_embeddings (line 41) | def get_text_embeddings( method spawn_func (line 73) | def spawn_func(pretrained_model_name_or_path, prompts, cache_dir, cfg): FILE: threestudio/models/renderers/base.py class Renderer (line 15) | class Renderer(BaseModule): class Config (line 17) | class Config(BaseModule.Config): method configure (line 22) | def configure( method forward (line 50) | def forward(self, *args, **kwargs) -> Dict[str, Any]: method geometry (line 54) | def geometry(self) -> BaseImplicitGeometry: method material (line 58) | def material(self) -> BaseMaterial: method background (line 62) | def background(self) -> BaseBackground: method set_geometry (line 65) | def set_geometry(self, geometry: BaseImplicitGeometry) -> None: method set_material (line 68) | def set_material(self, material: BaseMaterial) -> None: method set_background (line 71) | def set_background(self, background: BaseBackground) -> None: class VolumeRenderer (line 75) | class VolumeRenderer(Renderer): class Rasterizer (line 79) | class Rasterizer(Renderer): FILE: threestudio/models/renderers/mask_nerf_renderer.py class StableNeRFVolumeRenderer (line 20) | class StableNeRFVolumeRenderer(VolumeRenderer): class Config (line 22) | class Config(VolumeRenderer.Config): method configure (line 76) | def configure( method forward (line 151) | def forward( method update_step (line 590) | def update_step( method update_step_end (line 664) | def update_step_end(self, epoch: int, global_step: int) -> None: method train (line 672) | def train(self, mode=True): method eval (line 678) | def eval(self): FILE: threestudio/models/renderers/mask_nerf_renderer_multi.py class StableNeRFVolumeRendererMulti (line 16) | class StableNeRFVolumeRendererMulti(VolumeRenderer): class Config (line 18) | class Config(VolumeRenderer.Config): method configure (line 67) | def configure( method forward (line 104) | def forward( method update_step (line 364) | def update_step( method update_object_nerfs (line 372) | def update_object_nerfs(self, set_init: bool = False): method train (line 381) | def train(self, mode=True): method eval (line 387) | def eval(self): FILE: threestudio/models/renderers/stable_nerf_renderer.py class PatchRenderer (line 15) | class PatchRenderer(VolumeRenderer): class Config (line 17) | class Config(VolumeRenderer.Config): method configure (line 26) | def configure( method forward (line 51) | def forward( method update_step (line 133) | def update_step( method train (line 138) | def train(self, mode=True): method eval (line 141) | def eval(self): FILE: threestudio/models/renderers/stable_nerf_renderer_multi.py class PatchRenderer (line 15) | class PatchRenderer(VolumeRenderer): class Config (line 17) | class Config(VolumeRenderer.Config): method configure (line 26) | def configure( method forward (line 50) | def forward( method update_step (line 133) | def update_step( method train (line 139) | def train(self, mode=True): method eval (line 142) | def eval(self): FILE: threestudio/systems/base.py class BaseSystem (line 16) | class BaseSystem(pl.LightningModule, Updateable, SaverMixin): class Config (line 18) | class Config: method __init__ (line 30) | def __init__(self, cfg, resumed=False) -> None: method load_weights (line 45) | def load_weights(self, weights: str, ignore_modules: Optional[List[str... method set_resume_status (line 53) | def set_resume_status(self, current_epoch: int, global_step: int): method resumed (line 60) | def resumed(self): method true_global_step (line 65) | def true_global_step(self): method true_current_epoch (line 72) | def true_current_epoch(self): method configure (line 78) | def configure(self) -> None: method post_configure (line 81) | def post_configure(self) -> None: method C (line 87) | def C(self, value: Any) -> float: method configure_optimizers (line 90) | def configure_optimizers(self): method training_step (line 103) | def training_step(self, batch, batch_idx): method validation_step (line 106) | def validation_step(self, batch, batch_idx): method on_validation_batch_end (line 109) | def on_validation_batch_end(self, outputs, batch, batch_idx): method on_validation_epoch_end (line 114) | def on_validation_epoch_end(self): method test_step (line 117) | def test_step(self, batch, batch_idx): method on_test_batch_end (line 120) | def on_test_batch_end(self, outputs, batch, batch_idx): method on_test_epoch_end (line 125) | def on_test_epoch_end(self): method predict_step (line 128) | def predict_step(self, batch, batch_idx): method on_predict_batch_end (line 131) | def on_predict_batch_end(self, outputs, batch, batch_idx): method on_predict_epoch_end (line 136) | def on_predict_epoch_end(self): method preprocess_data (line 139) | def preprocess_data(self, batch, stage): method on_train_batch_start (line 147) | def on_train_batch_start(self, batch, batch_idx, unused=0): method on_validation_batch_start (line 153) | def on_validation_batch_start(self, batch, batch_idx, dataloader_idx=0): method on_test_batch_start (line 159) | def on_test_batch_start(self, batch, batch_idx, dataloader_idx=0): method on_predict_batch_start (line 165) | def on_predict_batch_start(self, batch, batch_idx, dataloader_idx=0): method update_step (line 171) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... method on_before_optimizer_step (line 174) | def on_before_optimizer_step(self, optimizer): class BaseLift3DSystem (line 184) | class BaseLift3DSystem(BaseSystem): class Config (line 186) | class Config(BaseSystem.Config): method configure (line 235) | def configure(self) -> None: method on_fit_start (line 289) | def on_fit_start(self) -> None: method on_test_end (line 297) | def on_test_end(self) -> None: method on_predict_start (line 301) | def on_predict_start(self) -> None: method predict_step (line 309) | def predict_step(self, batch, batch_idx): method on_predict_epoch_end (line 313) | def on_predict_epoch_end(self) -> None: method on_predict_end (line 324) | def on_predict_end(self) -> None: FILE: threestudio/systems/optimizers.py class Adan (line 23) | class Adan(Optimizer): method __init__ (line 48) | def __init__( method __setstate__ (line 82) | def __setstate__(self, state): method restart_opt (line 88) | def restart_opt(self): method step (line 104) | def step(self, closure=None): function _single_tensor_adan (line 200) | def _single_tensor_adan( function _multi_tensor_adan (line 257) | def _multi_tensor_adan( FILE: threestudio/systems/tc4d.py class TC4D (line 15) | class TC4D(BaseLift3DSystem): class Config (line 17) | class Config(BaseLift3DSystem.Config): method configure (line 35) | def configure(self) -> None: method get_prompt_processors (line 108) | def get_prompt_processors(self, prompt_processor, prompt_processor_type): method on_validation_start (line 125) | def on_validation_start(self) -> None: method on_test_start (line 130) | def on_test_start(self) -> None: method load_multi_ckpt_cfg (line 136) | def load_multi_ckpt_cfg(self): method forward (line 160) | def forward(self, batch: Dict[str, Any]) -> Dict[str, Any]: method on_fit_start (line 202) | def on_fit_start(self) -> None: method training_step (line 207) | def training_step(self, batch, batch_idx): method validation_step (line 367) | def validation_step(self, batch, batch_idx): method on_validation_epoch_end (line 564) | def on_validation_epoch_end(self): method test_step (line 567) | def test_step(self, batch, batch_idx): method on_test_epoch_end (line 758) | def on_test_epoch_end(self): FILE: threestudio/systems/utils.py function get_scheduler (line 12) | def get_scheduler(name): function getattr_recursive (line 19) | def getattr_recursive(m, attr): function get_parameters (line 25) | def get_parameters(model, name): function parse_optimizer (line 34) | def parse_optimizer(config, model): function parse_scheduler_to_instance (line 56) | def parse_scheduler_to_instance(config, optimizer): function parse_scheduler (line 74) | def parse_scheduler(config, optimizer): FILE: threestudio/utils/base.py class Configurable (line 11) | class Configurable: class Config (line 13) | class Config: method __init__ (line 16) | def __init__(self, cfg: Optional[dict] = None) -> None: class Updateable (line 21) | class Updateable: method do_update_step (line 22) | def do_update_step( method update_step (line 38) | def update_step(self, epoch: int, global_step: int, on_load_weights: b... function update_if_possible (line 45) | def update_if_possible(module: Any, epoch: int, global_step: int) -> None: class BaseObject (line 50) | class BaseObject(Updateable): class Config (line 52) | class Config: method __init__ (line 57) | def __init__( method configure (line 65) | def configure(self, *args, **kwargs) -> None: class BaseModule (line 69) | class BaseModule(nn.Module, Updateable): class Config (line 71) | class Config: method __init__ (line 76) | def __init__( method configure (line 97) | def configure(self, *args, **kwargs) -> None: FILE: threestudio/utils/bounding_boxes.py function scale_and_shift_box (line 3) | def scale_and_shift_box(size_min, size_max, rot_angle, translation, devi... function get_rotation_matrix (line 16) | def get_rotation_matrix(theta): function voxelize (line 25) | def voxelize(pc: torch.Tensor, voxel_size: int, grid_size=1., filter_out... function ravel_index (line 71) | def ravel_index(indices, shape, device): function shape_padright (line 76) | def shape_padright(x, n_ones=1): function dimshuffle (line 80) | def dimshuffle(x, pattern): function tensor_linspace (line 90) | def tensor_linspace(start, end, steps, device): FILE: threestudio/utils/callbacks.py class VersionedCallback (line 20) | class VersionedCallback(Callback): method __init__ (line 21) | def __init__(self, save_root, version=None, use_version=True): method version (line 27) | def version(self) -> int: method _get_next_version (line 37) | def _get_next_version(self): method savedir (line 50) | def savedir(self): class CodeSnapshotCallback (line 61) | class CodeSnapshotCallback(VersionedCallback): method __init__ (line 62) | def __init__(self, save_root, version=None, use_version=True): method get_file_list (line 65) | def get_file_list(self): method save_code_snapshot (line 81) | def save_code_snapshot(self): method on_fit_start (line 89) | def on_fit_start(self, trainer, pl_module): class ConfigSnapshotCallback (line 98) | class ConfigSnapshotCallback(VersionedCallback): method __init__ (line 99) | def __init__(self, config_path, config, save_root, version=None, use_v... method save_config_snapshot (line 105) | def save_config_snapshot(self): method on_fit_start (line 110) | def on_fit_start(self, trainer, pl_module): class CustomProgressBar (line 114) | class CustomProgressBar(TQDMProgressBar): method get_metrics (line 115) | def get_metrics(self, *args, **kwargs): FILE: threestudio/utils/config.py class ExperimentConfig (line 28) | class ExperimentConfig: method __post_init__ (line 60) | def __post_init__(self): function load_config (line 79) | def load_config(*yaml_files: str, cli_args: list = [], **kwargs) -> Any: function config_to_primitive (line 89) | def config_to_primitive(config, resolve: bool = True) -> Any: function dump_config (line 93) | def dump_config(path: str, config) -> None: function parse_structured (line 98) | def parse_structured(fields: Any, cfg: Optional[Union[dict, DictConfig]]... FILE: threestudio/utils/config_scene.py class ExperimentConfig (line 9) | class ExperimentConfig: method __post_init__ (line 13) | def __post_init__(self): function load_config (line 17) | def load_config(*yaml_files: str, cli_args: list = [], **kwargs) -> Any: function config_to_primitive (line 27) | def config_to_primitive(config, resolve: bool = True) -> Any: function dump_config (line 31) | def dump_config(path: str, config) -> None: function parse_structured (line 36) | def parse_structured(fields: Any, cfg: Optional[Union[dict, DictConfig]]... FILE: threestudio/utils/misc.py function parse_version (line 13) | def parse_version(ver: str): function get_rank (line 17) | def get_rank(): function get_device (line 28) | def get_device(): function load_module_weights (line 32) | def load_module_weights( function C (line 65) | def C(value: Any, epoch: int, global_step: int) -> float: function cleanup (line 89) | def cleanup(): function finish_with_cleanup (line 95) | def finish_with_cleanup(func: Callable): function _distributed_available (line 104) | def _distributed_available(): function barrier (line 108) | def barrier(): FILE: threestudio/utils/object_trajectory.py class SceneTrajectory (line 12) | class SceneTrajectory(torch.nn.Module): method __init__ (line 14) | def __init__( method update_objs (line 32) | def update_objs(self, frame_times): class ObjectTrajectory (line 37) | class ObjectTrajectory(torch.nn.Module): method __init__ (line 39) | def __init__( method set_translation_offsets (line 59) | def set_translation_offsets(self): method update_obj (line 67) | def update_obj(self, frame_time: float): method get_lengths (line 79) | def get_lengths(self): method get_pos (line 86) | def get_pos(self): method get_rot (line 89) | def get_rot(self): class GeneralTrajectory (line 93) | class GeneralTrajectory(torch.nn.Module): method __init__ (line 95) | def __init__( method set_pos_init (line 130) | def set_pos_init(self): method estimator_res (line 134) | def estimator_res(self): method est_size (line 138) | def est_size(self): method device (line 142) | def device(self): method update_obj (line 145) | def update_obj(self, frame_time: float): method get_translation_rotation (line 155) | def get_translation_rotation(self, frame_time: float): method set_translation_offset (line 163) | def set_translation_offset(self, translation_end_previous: torch.Tenso... method reset_estimator (line 169) | def reset_estimator(self): method get_rotation_mat (line 173) | def get_rotation_mat(self, rotation: float, frame_time: float): method set_estimator (line 183) | def set_estimator(self, position: List[float], rotation: float): class SplineTrajectory (line 214) | class SplineTrajectory(GeneralTrajectory): method __init__ (line 216) | def __init__( method set_pos_init (line 240) | def set_pos_init(self): method eval_spline (line 243) | def eval_spline( method get_translation (line 256) | def get_translation(self, frame_time: float, **kwargs): method get_rotation (line 260) | def get_rotation(self, frame_time: float): method calc_length (line 267) | def calc_length(self): method segment_spline (line 270) | def segment_spline(self, segment_count: int = 1000): method transform_time (line 278) | def transform_time(self, u: np.ndarray): class CurvatureTrajectory (line 291) | class CurvatureTrajectory(GeneralTrajectory): method __init__ (line 293) | def __init__( method set_pos_init (line 308) | def set_pos_init(self): method get_translation (line 312) | def get_translation(self, rotation: float, **kwargs): method get_rotation (line 317) | def get_rotation(self, frame_time: float): method calc_length (line 323) | def calc_length(self): class StaticTrajectory (line 327) | class StaticTrajectory(GeneralTrajectory): method __init__ (line 329) | def __init__( method set_pos_init (line 341) | def set_pos_init(self): method get_translation (line 344) | def get_translation(self, rotation: float, **kwargs): method get_rotation (line 349) | def get_rotation(self, frame_time: float): method calc_length (line 353) | def calc_length(self): FILE: threestudio/utils/ops.py function load_resize_image (line 18) | def load_resize_image(img_path, h, w): function dot (line 28) | def dot(x, y): function reflect (line 32) | def reflect(x, n): function scale_tensor (line 39) | def scale_tensor( class _TruncExp (line 53) | class _TruncExp(Function): # pylint: disable=abstract-method method forward (line 58) | def forward(ctx, x): # pylint: disable=arguments-differ method backward (line 64) | def backward(ctx, g): # pylint: disable=arguments-differ class SpecifyGradient (line 69) | class SpecifyGradient(Function): method forward (line 74) | def forward(ctx, input_tensor, gt_grad): method backward (line 81) | def backward(ctx, grad_scale): function get_activation (line 90) | def get_activation(name) -> Callable: function chunk_batch (line 125) | def chunk_batch(func: Callable, chunk_size: int, *args, **kwargs) -> Any: function get_ray_directions (line 192) | def get_ray_directions( function get_rays (line 232) | def get_rays( function get_projection_matrix (line 279) | def get_projection_matrix( function get_mvp_matrix (line 294) | def get_mvp_matrix( function binary_cross_entropy (line 308) | def binary_cross_entropy(input, target): function tet_sdf_diff (line 315) | def tet_sdf_diff( class MeshOBJ (line 331) | class MeshOBJ: method __init__ (line 337) | def __init__(self, v: np.ndarray, f: np.ndarray): method normalize_mesh (line 355) | def normalize_mesh(self, target_scale=0.5): method winding_number (line 367) | def winding_number(self, query: torch.Tensor): method gaussian_weighted_distance (line 376) | def gaussian_weighted_distance(self, query: torch.Tensor, sigma): function ce_pq_loss (line 388) | def ce_pq_loss(p, q, weight=None): class ShapeLoss (line 399) | class ShapeLoss(nn.Module): method __init__ (line 400) | def __init__(self, guide_shape): method forward (line 419) | def forward(self, xyzs, sigmas): class TVLoss (line 435) | class TVLoss(nn.Module): method __init__ (line 436) | def __init__(self, TVLoss_weight_dim1=1.0, TVLoss_weight_dim2=1.0): method forward (line 441) | def forward(self, x): method _tensor_size (line 457) | def _tensor_size(self, t): method __init__ (line 469) | def __init__(self, tv_loss_weight=[1.0, 1.0, 1.0]): method forward (line 473) | def forward(self, x): method _tensor_size (line 479) | def _tensor_size(self, t): function validate_empty_rays (line 460) | def validate_empty_rays(ray_indices, t_start, t_end): class TVLoss (line 468) | class TVLoss(nn.Module): method __init__ (line 436) | def __init__(self, TVLoss_weight_dim1=1.0, TVLoss_weight_dim2=1.0): method forward (line 441) | def forward(self, x): method _tensor_size (line 457) | def _tensor_size(self, t): method __init__ (line 469) | def __init__(self, tv_loss_weight=[1.0, 1.0, 1.0]): method forward (line 473) | def forward(self, x): method _tensor_size (line 479) | def _tensor_size(self, t): FILE: threestudio/utils/rasterize.py class NVDiffRasterizerContext (line 7) | class NVDiffRasterizerContext: method __init__ (line 8) | def __init__(self, context_type: str, device: torch.device) -> None: method initialize_context (line 12) | def initialize_context( method vertex_transform (line 22) | def vertex_transform( method rasterize (line 30) | def rasterize( method rasterize_one (line 39) | def rasterize_one( method antialias (line 49) | def antialias( method interpolate (line 58) | def interpolate( method interpolate_one (line 70) | def interpolate_one( FILE: threestudio/utils/saving.py class SaverMixin (line 23) | class SaverMixin: method set_save_dir (line 27) | def set_save_dir(self, save_dir: str): method get_save_dir (line 30) | def get_save_dir(self): method convert_data (line 35) | def convert_data(self, data): method get_save_path (line 52) | def get_save_path(self, filename): method create_loggers (line 57) | def create_loggers(self, cfg_loggers: DictConfig) -> None: method get_loggers (line 65) | def get_loggers(self) -> List: method get_rgb_image_ (line 80) | def get_rgb_image_(self, img, data_format, data_range, rgba=False): method _save_rgb_image (line 114) | def _save_rgb_image( method save_rgb_image (line 133) | def save_rgb_image( method get_uv_image_ (line 146) | def get_uv_image_(self, img, data_format, data_range, cmap): method save_uv_image (line 169) | def save_uv_image( method get_grayscale_image_ (line 180) | def get_grayscale_image_(self, img, data_range, cmap): method save_grayscale_image (line 234) | def save_grayscale_image( method get_image_grid_ (line 244) | def get_image_grid_(self, imgs, align): method save_image_grid (line 298) | def save_image_grid( method save_image (line 324) | def save_image(self, filename, img): method save_cubemap (line 333) | def save_cubemap(self, filename, img, data_range=(0, 1), rgba=False): method save_data (line 366) | def save_data(self, filename, data): method save_state_dict (line 377) | def save_state_dict(self, filename, data): method save_img_sequence (line 380) | def save_img_sequence( method save_mesh (line 421) | def save_mesh(self, filename, v_pos, t_pos_idx, v_tex=None, t_tex_idx=... method save_obj (line 427) | def save_obj( method _save_obj (line 479) | def _save_obj( method _save_mtl (line 522) | def _save_mtl( method save_file (line 581) | def save_file(self, filename, src_path): method save_json (line 584) | def save_json(self, filename, payload):