MCPcopy Create free account

hub / github.com/NVIDIA/DreamDojo / functions

Functions3,821 in github.com/NVIDIA/DreamDojo

↓ 246 callersMethodget
Read data from a given ``filepath`` with 'rb' mode. Note: There are two types of return values for ``get``, one is ``bytes``
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:287
↓ 191 callersMethoditems
(self)
cosmos_predict2/_src/imaginaire/utils/registry.py:70
↓ 156 callersMethodlog
(self, metrics: Dict[str, Any], step: int)
cosmos_predict2/_src/reason1/parallelisms/metrics.py:112
↓ 116 callersMethodkeys
(self)
cosmos_predict2/_src/imaginaire/utils/registry.py:67
↓ 110 callersMethodexists
Check whether a file path exists. Args: filepath (str or Path): Path to be checked whether exists. Returns:
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:354
↓ 85 callersMethodsize
(self)
cosmos_predict2/_src/predict2/utils/kv_cache.py:344
↓ 68 callersFunctionlog_verbose
Print a message only if VERBOSE environment variable is set to 1. Args: message: The message to print
packages/cosmos-oss/vqa/utils.py:27
↓ 63 callersMethodis_initialized
(self)
cosmos_predict2/_src/predict2/interactive/inference/action_video2world.py:37
↓ 60 callersMethodupdate
(self, cur_state: torch.Tensor)
cosmos_predict2/_src/predict2/callbacks/grad_clip.py:42
↓ 57 callersFunctionlog_info
Print a message regardless of VERBOSE setting. Use for important information, summaries, and critical messages. Args: message: T
packages/cosmos-oss/vqa/utils.py:38
↓ 52 callersMethodsynchronize
Synchronize all processes in distributed mode.
cosmos_predict2/_src/predict2/inference/interpolator_lib.py:245
↓ 48 callersMethodload
( self, model: ImaginaireModel, optimizer: torch.optim.Optimizer | None = None,
cosmos_predict2/_src/predict2/checkpointer/dcp.py:546
↓ 46 callersMethoddevice
(self)
external/lam/modules/embeddings.py:135
↓ 43 callersFunctionbuild_debug_runs
(job)
cosmos_predict2/_src/predict2/configs/video2world/experiment/resume_text2world/state3_14B_index_3.py:67
↓ 42 callersMethodstate_dict
(self, mapping_keys: dict[str, str] = {})
cosmos_predict2/_src/predict2/checkpointer/dcp.py:272
↓ 41 callersMethoddecode
(self, latent: torch.Tensor)
cosmos_predict2/_src/predict2/tokenizers/base_vae.py:449
↓ 40 callersFunctionbroadcast_split_tensor
Broadcast the tensor from the minimum rank in the specified group(s).
cosmos_predict2/_src/imaginaire/utils/context_parallel.py:197
↓ 38 callersMethodedit_data_type
Edit the data type of the condition. Args: data_type: The new data type. Returns: A new Text2WorldCondition
cosmos_predict2/_src/predict2/conditioner.py:113
↓ 38 callersMethodto_dict
Converts the condition to a dictionary. Returns: Dictionary containing the condition's fields and values.
cosmos_predict2/_src/predict2/conditioner.py:78
↓ 37 callersMethodis_image_batch
We hanlde two types of data_batch. One comes from a joint_dataloader where "dataset_name" can be used to differenciate image_batch and video_batch.
cosmos_predict2/_src/predict2/models/text2world_model.py:872
↓ 37 callersMethodread
r"""Read function for reading the data stream. Args: amt (int, optional): Amount of data to read Returns: chun
cosmos_predict2/_src/imaginaire/datasets/webdataset/utils/stream.py:48
↓ 36 callersFunctionbuild_debug_runs
(job)
cosmos_predict2/_src/predict2/configs/video2world/experiment/reason_embeddings/stage3_2B.py:48
↓ 34 callersMethodeval
(self)
groot_dreams/data/transform/base.py:68
↓ 31 callersFunction_register_checkpoint
(checkpoint_config: CheckpointConfig)
cosmos_predict2/_src/imaginaire/utils/checkpoint_db.py:179
↓ 30 callersMethodget_context_parallel_group
()
cosmos_predict2/_src/predict2/models/text2world_model.py:404
↓ 27 callersFunctionbuild_debug_runs
(job)
cosmos_predict2/_src/predict2/configs/video2world/experiment/resume_text2world/stage3_2B_ablation.py:67
↓ 27 callersMethodload
Load a config file. Args: filename: absolute path or relative path w.r.t. the current working directory keys
cosmos_predict2/_src/imaginaire/lazy_config/lazy.py:253
↓ 25 callersMethodload
Load network weights and optimizer states from a checkpoint in a single process. The priority of the checkpoint loading logic is: 1.
cosmos_predict2/_src/imaginaire/utils/checkpointer.py:160
↓ 24 callersFunctionget_file_backend
Return a file backend based on the prefix of uri or backend_args. Args: uri (str or Path): Uri to be parsed that contains the file prefix
cosmos_predict2/_src/imaginaire/utils/easy_io/easy_io.py:105
↓ 24 callersMethodset_video_condition
Sets the video conditioning frames for video-to-video generation. This method creates a conditioning mask for the input video frames
cosmos_predict2/_src/predict2/configs/video2world/defaults/conditioner.py:47
↓ 23 callersMethodbroadcast_split_for_model_parallelsim
Broadcast and split the input data and condition for model parallelism. Currently, we only support context parallelism.
cosmos_predict2/_src/predict2/models/text2world_model.py:409
↓ 22 callersFunctioninstantiate
Recursively instantiate objects defined in dictionaries by "_target_" and arguments. Args: cfg: a dict-like object with "_target
cosmos_predict2/_src/imaginaire/lazy_config/instantiate.py:56
↓ 21 callersFunctionprint_if_verbose
(*args, **kwargs)
cosmos_predict2/_src/predict2/utils/model_comp.py:35
↓ 20 callersMethod_translate_filepath
Translate a `filepath` to a string. Paths are of the form 'path/to/file' (path form) or '{protocol}://path/to/file' (URL form). Args
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/msc_backend.py:157
↓ 18 callersMethod_format_path
Convert a ``filepath`` to standard format of s3 oss. If the ``filepath`` is concatenated by ``os.path.join``, in a Windows environmen
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/boto3_backend.py:85
↓ 18 callersMethod_map_path
Map ``filepath`` to a string path whose prefix will be replaced by :attr:`self.path_mapping`. Args: filepath (str or Path
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/boto3_backend.py:72
↓ 18 callersMethodcompute_text_embeddings_online
Compute text embeddings for the given prompts.
cosmos_predict2/_src/predict2/text_encoders/text_encoder.py:131
↓ 18 callersMethodremove
Remove a file. Args: filepath (str, Path): Path to be removed.
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:346
↓ 17 callersMethodapply
(self, data: dict[str, Any])
groot_dreams/data/transform/video.py:139
↓ 17 callersMethodload
( self, model: ImaginaireModel, optimizer: torch.optim.Optimizer | None = None,
cosmos_predict2/_src/predict2/distill/checkpointer/dcp.py:501
↓ 16 callersMethod__init__
(self, config)
cosmos_predict2/_src/reason1/networks/qwen2_vl.py:522
↓ 16 callersFunctionbatch_mul
(x: Tensor, y: Tensor)
cosmos_predict2/_src/imaginaire/functional/batch_ops.py:49
↓ 16 callersFunctionget_text_embedding
Encodes text prompts into T5 embeddings. Args: prompts: A single text prompt or a list of text prompts. encoder: An optional Cosm
cosmos_predict2/_src/predict2/inference/get_t5_emb.py:133
↓ 16 callersMethodload_state_dict
(self, state_dict)
cosmos_predict2/_src/imaginaire/utils/fused_adam.py:354
↓ 16 callersMethodstate_dict
(self)
cosmos_predict2/_src/predict2/distill/checkpointer/dcp.py:223
↓ 16 callersMethodto_rotation_matrix
Convert quaternion(s) to rotation matrix/matrices. Args: q (torch.Tensor [...,4]): Quaternion(s) (x, y, z, w). Returns:
cosmos_predict2/_src/imaginaire/modules/camera.py:519
↓ 15 callersMethod__init__
(self, config)
cosmos_predict2/_src/reason1/networks/qwen2_5_vl.py:645
↓ 15 callersFunctionbuild_debug_runs
(job)
cosmos_predict2/_src/predict2/configs/video2world/experiment/resume_text2world/sparse_2B.py:229
↓ 15 callersFunctionget_checkpoint_by_uuid
Return checkpoint config for UUID.
cosmos_predict2/_src/imaginaire/utils/checkpoint_db.py:904
↓ 15 callersFunctionget_local_tensor_if_DTensor
(tensor: torch.Tensor | DTensor)
cosmos_predict2/_src/reason1/utils/fused_adam.py:25
↓ 15 callersFunctionget_local_tensor_if_DTensor
(tensor: torch.Tensor | DTensor)
cosmos_predict2/_src/imaginaire/utils/misc.py:481
↓ 15 callersMethodput
Write data to a given ``filepath`` with 'wb' mode. Note: ``put`` should create a directory if the directory of ``filepath``
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:318
↓ 14 callersMethod__init__
( self, x_dim: int, context_dim: int, num_heads: int, mlp_ratio: float
cosmos_predict2/_src/predict2/camera/networks/dit_multiview_camera.py:1022
↓ 14 callersMethod__init__
( self, x_dim: int, context_dim: int, num_heads: int, mlp_ratio: float
cosmos_predict2/_src/predict2/camera/networks/dit_multiview_camera_ar.py:1023
↓ 14 callersFunctioncat_outputs_cp
Concatenate outputs from different ranks in the checkpoint parallelism group. This function gathers tensors from all ranks in the checkpoint
cosmos_predict2/_src/imaginaire/utils/context_parallel.py:66
↓ 14 callersMethoddenoise
Performs denoising on the input noise data, noise level, and condition Args: xt (torch.Tensor): The input noise data.
cosmos_predict2/_src/predict2/models/text2world_model.py:883
↓ 14 callersMethodencode
state : pixel range [-1, 1]
cosmos_predict2/_src/predict2/tokenizers/base_vae.py:428
↓ 14 callersFunctionget_checkpoint_path
Return checkpoint path for S3 URI, HuggingFace URI, or local path. Supports: - S3 URIs: s3://bucket/path/to/checkpoint - HuggingFace URIs
cosmos_predict2/_src/imaginaire/utils/checkpoint_db.py:944
↓ 14 callersMethodget_latent_num_frames
(self, num_pixel_frames: int)
cosmos_predict2/_src/predict2/tokenizers/wan2pt1.py:1032
↓ 14 callersMethodscaled_dot_product_attention
( self, query: Tensor, key: Tensor, value: Tensor, is_causal: bool = F
external/lam/modules/blocks.py:58
↓ 13 callersMethod__init__
( self, x_dim: int, context_dim: int, num_heads: int, mlp_ratio: float
cosmos_predict2/_src/predict2/networks/minimal_v4_dit.py:1168
↓ 13 callersMethodbroadcast
Broadcasts and splits the condition across the checkpoint parallelism group. For most condition, such as Text2WorldCondition, we do not need s
cosmos_predict2/_src/predict2/conditioner.py:91
↓ 13 callersMethodclose
(self)
cosmos_predict2/_src/imaginaire/checkpointer/s3_filesystem.py:38
↓ 13 callersMethodget_condition_uncondition
Processes the provided data batch to generate two sets of outputs: conditioned and unconditioned. This method manipulates the dropout
cosmos_predict2/_src/predict2/conditioner.py:502
↓ 13 callersMethodget_condition_with_negative_prompt
Similar functionality as get_condition_uncondition But use negative prompts for unconditon
cosmos_predict2/_src/predict2/conditioner.py:533
↓ 13 callersMethodmkdir
Create a "directory" in S3. Note: S3 doesn't have real directories, but we can create an empty object with a trailing slash
cosmos_predict2/_src/imaginaire/checkpointer/s3_filesystem.py:200
↓ 13 callersMethodsave
Save network weights, optimizer parameters, scheduler parameters to a checkpoint. Args: model (ImaginaireModel): The PyTorch mode
cosmos_predict2/_src/imaginaire/utils/checkpointer.py:70
↓ 13 callersMethodstate_dict
(self)
cosmos_predict2/_src/reason1/parallelisms/dcp_checkpointer.py:91
↓ 13 callersMethodvisual
(self, videos_B_C_H_W_n1_p1)
cosmos_predict2/_src/predict2/networks/clip.py:529
↓ 12 callersMethod__init__
( self, z_dim=48, vae_pth="s3://bucket/cosmos_diffusion_v2/pretrain_weights/tokenizer/
cosmos_predict2/_src/predict2/tokenizers/wan2pt2.py:879
↓ 12 callersFunction_random_unit_quaternion
(batch_shape=())
cosmos_predict2/_src/imaginaire/modules/camera_test.py:17
↓ 12 callersMethodbackward
( ctx, grad_out: Tensor, grad_lse: Tensor )
cosmos_predict2/_src/imaginaire/attention/cudnn/functions.py:154
↓ 12 callersMethodbroadcast
(self, process_group: torch.distributed.ProcessGroup)
cosmos_predict2/_src/predict2/configs/video2world/defaults/conditioner.py:147
↓ 12 callersFunctionbuild_no_s3_run
Make a copy of the input config that doesn't require S3 for checkpointing and I/O in the callbacks.
cosmos_predict2/_src/predict2/distill/utils/config_helper.py:21
↓ 12 callersMethodcopyfile_from_local
Upload a local file src to dst and return the destination file. Args: src (str or Path): A local file to be copied. d
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/msc_backend.py:552
↓ 12 callersFunctioncount_params
(model: nn.Module, verbose=False)
cosmos_predict2/_src/imaginaire/utils/count_params.py:19
↓ 12 callersFunctioneuler2rotm
Euler angle (ZYX) to rotation matrix.
cosmos_predict2/_src/predict2/action/datasets/dataset_utils.py:128
↓ 12 callersFunctionget_arch_tag
Returns the compute capability of a given torch device if it's a CUDA device, otherwise returns 0. Args: device (torch.device | None
cosmos_predict2/_src/imaginaire/attention/utils/__init__.py:31
↓ 12 callersFunctionget_data_path
(embodiment)
groot_dreams/dataloader.py:230
↓ 12 callersFunctionimport_all_modules_from_package
Import all modules from the specified package path recursively. This function is typically used in conjunction with Hydra to ensure that all
cosmos_predict2/_src/imaginaire/utils/config_helper.py:175
↓ 12 callersMethodnormalize
Normalize quaternion(s) to unit length. Args: q (torch.Tensor [...,4]): Input quaternion(s). eps (float): Small epsil
cosmos_predict2/_src/imaginaire/modules/camera.py:497
↓ 12 callersMethodsave
Save network weights, optimizer parameters, scheduler parameters to a checkpoint. Args: model (ImaginaireModel): The PyTorch mode
cosmos_predict2/_src/imaginaire/checkpointer/ddp.py:109
↓ 12 callersMethodsize
Get the file size in bytes for a given ``filepath``. Args: filepath (str or Path): Path to get file size in bytes. Retur
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/msc_backend.py:195
↓ 11 callersMethod_augment_image_dim_inplace
(self, data_batch: dict[str, Tensor], input_key: str = None)
cosmos_predict2/_src/predict2/models/text2world_model.py:786
↓ 11 callersFunctionbroadcast_dtensor_model_states
Broadcast model states from replicate mesh's rank 0.
cosmos_predict2/_src/predict2/utils/dtensor_helper.py:73
↓ 11 callersMethodinit_weights
(self)
cosmos_predict2/_src/predict2/networks/wan2pt1.py:593
↓ 11 callersFunctionis_blackwell_dc
(device: torch.device | None = None)
cosmos_predict2/_src/imaginaire/attention/utils/__init__.py:70
↓ 11 callersFunctionis_torch_compiling
()
cosmos_predict2/_src/imaginaire/attention/utils/environment.py:30
↓ 11 callersMethodisfile
Check whether a file path is a file. Args: filepath (str or Path): Path to be checked whether it is a file. Returns:
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:378
↓ 11 callersMethodreset_parameters
(self)
cosmos_predict2/_src/predict2/networks/wan2pt1.py:253
↓ 11 callersMethodrun
(self, script: str, env: dict)
packages/cosmos-oss/cosmos_oss/fixtures/script.py:150
↓ 10 callersMethod_forward
r""" Args: labels (`torch.LongTensor` of shape `(batch_size, sequence_length)`, *optional*): Labels for computing
cosmos_predict2/_src/predict2/text_encoders/reason1.py:46
↓ 10 callersMethod_normalize_video_databatch_inplace
Normalizes video data in-place on a CUDA device to reduce data loading overhead. This function modifies the video data tensor within
cosmos_predict2/_src/predict2/models/text2world_model.py:741
↓ 10 callersMethod_replace_prefix
(self, filepath: Union[str, Path])
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/boto3_backend.py:98
↓ 10 callersFunctionbuild_debug_runs
(job)
cosmos_predict2/_src/predict2/configs/video2world/experiment/reason_embeddings/model_2B_reason_1p1.py:48
↓ 10 callersMethodcopyfile_to_local
Copy the file src to local dst and return the destination file. If dst specifies a directory, the file will be copied into dst using
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/msc_backend.py:627
↓ 10 callersMethodfully_shard
(self, mesh)
cosmos_predict2/_src/predict2/networks/wan2pt1.py:948
↓ 10 callersMethodget_context_parallel_group
()
cosmos_predict2/_src/predict2/models/text2world_model_rectified_flow.py:407
↓ 10 callersMethodmodel
(self)
cosmos_predict2/_src/imaginaire/functional/lr_scheduler.py:53
↓ 10 callersFunctionnon_strict_load_model
(model: torch.nn.Module, checkpoint_state_dict: dict)
cosmos_predict2/_src/imaginaire/utils/checkpointer.py:444
next →1–100 of 3,821, ranked by callers