MCPcopy Create free account

hub / github.com/NVIDIA/DreamDojo / functions

Functions3,821 in github.com/NVIDIA/DreamDojo

↓ 2 callersMethodmodel_dict
(self)
cosmos_predict2/_src/predict2/distill/models/distillation_base_mixin.py:834
↓ 2 callersMethodmodel_dump
(self, *args, **kwargs)
groot_dreams/data/transform/state_action.py:212
↓ 2 callersMethodmodel_dump
(self, *args, **kwargs)
groot_dreams/data/transform/concat.py:48
↓ 2 callersFunctionmulti_dim_attention_param_checks
Validates multi-dimensional parameters.
cosmos_predict2/_src/imaginaire/attention/checks.py:461
↓ 2 callersFunctionmulti_dim_attention_param_filter
Converts all multi-dimensional parameters to standard types.
cosmos_predict2/_src/imaginaire/attention/checks.py:420
↓ 2 callersFunctionmulti_dim_attention_tensor_checks
( query: Tensor, key: Tensor, value: Tensor, supported_dtypes_forward: list[torch.dtype] | Non
cosmos_predict2/_src/imaginaire/attention/checks.py:356
↓ 2 callersFunctionobtain_image_size
r"""Function for obtaining the image size from the data dict. Args: data_dict (dict): Input data dict input_keys (list): List of
cosmos_predict2/_src/predict2/datasets/local_datasets/dataset_utils.py:23
↓ 2 callersMethodon_after_forward
(self, iteration: int = 0)
cosmos_predict2/_src/imaginaire/utils/callback.py:161
↓ 2 callersMethodon_app_end
(self)
cosmos_predict2/_src/imaginaire/utils/callback.py:306
↓ 2 callersMethodon_before_backward
( self, model_ddp: distributed.DistributedDataParallel, loss: torch.Tensor, iteration: int = 0 )
cosmos_predict2/_src/imaginaire/utils/callback.py:164
↓ 2 callersMethodon_before_forward
(self, iteration: int = 0)
cosmos_predict2/_src/imaginaire/utils/callback.py:158
↓ 2 callersMethodon_before_zero_grad
update the net_ema
cosmos_predict2/_src/predict2/distill/models/distillation_base_mixin.py:333
↓ 2 callersMethodon_optimizer_init_end
(self)
cosmos_predict2/_src/imaginaire/utils/callback.py:181
↓ 2 callersMethodon_optimizer_init_start
(self)
cosmos_predict2/_src/imaginaire/utils/callback.py:178
↓ 2 callersMethodon_train_start
(self, memory_format: torch.memory_format = torch.preserve_format)
cosmos_predict2/_src/predict2/models/text2world_model.py:314
↓ 2 callersMethodon_train_start
The model preparation before the training is launched Args: memory_format (torch.memory_format): Memory format of the model.
cosmos_predict2/_src/imaginaire/model.py:100
↓ 2 callersMethodon_training_step_batch_end
Called at the end of a training step for every batch even when using gradient accumulation. This is paired with on_training_step_batc
cosmos_predict2/_src/imaginaire/utils/callback.py:203
↓ 2 callersMethodon_training_step_batch_start
Called before the training step, for each batch, similarly to on_training_step_start(). This function is paired with on_training_step
cosmos_predict2/_src/imaginaire/utils/callback.py:148
↓ 2 callersMethodon_validation_step_start
( self, model: ImaginaireModel, data: dict[str, torch.Tensor], iteration: int = 0 )
cosmos_predict2/_src/imaginaire/utils/callback.py:239
↓ 2 callersMethodpad_context_2d
2D context padding: simultaneously perform padding on both height and width dimensions
cosmos_predict2/_src/predict2/tokenizers/wan2pt1_2d_plugins.py:169
↓ 2 callersFunctionpatch_device
(module)
cosmos_predict2/_src/imaginaire/modules/image_embeddings.py:720
↓ 2 callersFunctionpatch_float
(module)
cosmos_predict2/_src/imaginaire/modules/image_embeddings.py:744
↓ 2 callersFunctionpath_to_str
Convert optional path to optional string.
cosmos_predict2/config.py:40
↓ 2 callersFunctionphi1
Compute the first order phi function: (exp(t) - 1) / t. Args: t: Input tensor. Returns: Tensor: Result of phi1 function
cosmos_predict2/_src/imaginaire/functional/runge_kutta.py:23
↓ 2 callersFunctionpost_all2all
r"""Creates a post-merging function after all-to-all communication. Args: local_seq_2_local_head (bool): If True, moves sequence dimension
cosmos_predict2/_src/predict2/interactive/networks/ulysses.py:48
↓ 2 callersMethodpostprocess
Run the postprocessing on the video frames.
cosmos_predict2/_src/imaginaire/auxiliary/guardrail/common/core.py:65
↓ 2 callersMethodprepare_random_slice
(self, epsilon_B_C_T_H_W)
cosmos_predict2/_src/predict2/distill/models/video2world_model_distill_dmd2.py:405
↓ 2 callersFunctionprocess_sample
(sample, url, key_idx)
cosmos_predict2/_src/imaginaire/datasets/webdataset/utils/iterators.py:192
↓ 2 callersMethodput
(self, obj, filepath)
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/boto3_client.py:407
↓ 2 callersMethodput_text
Write data to a given ``filepath`` with 'w' mode. Note: ``put_text`` should create a directory if the directory of ``
cosmos_predict2/_src/imaginaire/utils/easy_io/file_client.py:331
↓ 2 callersMethodrandom_dropout_input
( self, in_tensor: torch.Tensor, dropout_rate: Optional[float] = None, key: Optional[str] = None )
cosmos_predict2/_src/predict2/conditioner.py:271
↓ 2 callersFunctionread_video
Read a video file and extract its frames and metadata.
cosmos_predict2/_src/imaginaire/auxiliary/guardrail/common/io_utils.py:42
↓ 2 callersFunctionregister_callbacks
()
cosmos_predict2/_src/predict2/configs/text2world/defaults/callbacks.py:46
↓ 2 callersFunctionregister_interactive_data
()
cosmos_predict2/_src/predict2/interactive/configs/data.py:193
↓ 2 callersFunctionregister_model
()
cosmos_predict2/_src/predict2/interactive/configs/model.py:57
↓ 2 callersFunctionregister_net
()
cosmos_predict2/_src/predict2/interactive/configs/net.py:85
↓ 2 callersFunctionregister_net_discriminator_head
()
cosmos_predict2/_src/predict2/distill/configs/defaults/discriminator.py:36
↓ 2 callersMethodremove
Remove a file. Args: filepath (str or Path): Path to be removed. Raises: FileNotFoundError: If filepath does
cosmos_predict2/_src/imaginaire/utils/easy_io/backends/boto3_backend.py:625
↓ 2 callersFunctionrepeat_list
r"""Function to repeat the list to a fixed shape. n is the desired length of the extended list. Args: x (list): Input list n (
cosmos_predict2/_src/imaginaire/datasets/webdataset/utils/misc.py:20
↓ 2 callersFunctionreplace_selfattn_op_with_sparse_attn_op
Replace the self-attention operator with a sparse self-attention operator. Args: model: MiniTrainDIT instance n_dense_blocks
cosmos_predict2/_src/predict2/networks/minimal_v4_dit.py:1919
↓ 2 callersMethodreport
(self, iteration: int = 0)
cosmos_predict2/_src/predict2/callbacks/heart_beat.py:87
↓ 2 callersMethodreport
Reports measurements.
cosmos_predict2/_src/imaginaire/utils/timer.py:163
↓ 2 callersFunctionres_x0_rk2_step
Perform a residual-based 2nd order Runge-Kutta step. Args: x_s: Current state tensor. t: Target time tensor. s: Curr
cosmos_predict2/_src/imaginaire/functional/runge_kutta.py:53
↓ 2 callersMethodreset
(self)
cosmos_predict2/_src/predict2/callbacks/wandb_log.py:39
↓ 2 callersMethodreset
Resets recorded measurements
cosmos_predict2/_src/imaginaire/utils/timer.py:232
↓ 2 callersMethodreset_kv_cache
Reset/initialize the KV caches. Only has effect in stateful mode. In stateless mode this is a no-op. Args: max_cache_si
cosmos_predict2/_src/predict2/utils/kv_cache.py:100
↓ 2 callersFunctionresize_image
(image: torch.Tensor, size: int = 1024)
cosmos_predict2/_src/predict2/distill/callbacks/every_n_draw_sample_scm.py:40
↓ 2 callersFunctionresize_image
Resize the image to the given size. This is done so that wandb can display the image correctly.
cosmos_predict2/_src/predict2/callbacks/validation_draw_sample.py:38
↓ 2 callersFunctionresize_input
r""" Resizes and crops the input video tensor while preserving aspect ratio. The video is first resized so that the smaller dimension matches
cosmos_predict2/_src/predict2/inference/utils.py:64
↓ 2 callersFunctionrobust_broadcast
Perform a robust broadcast operation that works regardless of tensor shapes on different ranks. The function is decorated with @torch.compil
cosmos_predict2/_src/imaginaire/utils/context_parallel.py:144
↓ 2 callersFunctionrope_apply
Optimized version of rope_apply using flash_attention's rotary embedding implementation. This version processes the entire batch at once for
cosmos_predict2/_src/predict2/networks/wan2pt1.py:214
↓ 2 callersMethodrotate_queries_or_keys
(self, t, freqs, seq_dim=None, offset=0, scale=None)
external/lam/modules/embeddings.py:141
↓ 2 callersMethodrotate_queries_or_keys
(self, t, freqs, seq_dim=None, offset=0, scale=None)
external/lam_project/lam/modules/embeddings.py:141
↓ 2 callersMethodrun_batch
Run VQA inference on a video with multiple questions from a YAML file. Args: video_path: Path to the video file
packages/cosmos-oss/vqa/evaluator.py:205
↓ 2 callersMethodrun_save
(self, to_show, batch_size, base_fp_wo_ext)
cosmos_predict2/_src/predict2/distill/callbacks/every_n_draw_sample_scm.py:384
↓ 2 callersMethodrun_save
(self, to_show, batch_size, iteration, save_name)
cosmos_predict2/_src/predict2/callbacks/validation_draw_sample.py:360
↓ 2 callersMethodrun_save
(self, to_show, batch_size, base_fp_wo_ext)
cosmos_predict2/_src/predict2/callbacks/every_n_draw_sample.py:331
↓ 2 callersFunctionsample_image
(fname: str)
packages/cosmos-gradio/sample/api_client.py:30
↓ 2 callersMethodsample_train_time
r"""This method calls the `TrainTimeSampler` to sample training times. Returns: t (`torch.Tensor`): A tensor of s
cosmos_predict2/_src/predict2/schedulers/rectified_flow.py:115
↓ 2 callersMethodsave
Save network weights, optimizer parameters, scheduler parameters to a checkpoint. Args: model (ImaginaireModel): The PyTorch mode
cosmos_predict2/_src/predict2/checkpointer/dcp.py:715
↓ 2 callersMethodsave
Save network weights, optimizer parameters, scheduler parameters to a checkpoint. Args: model (ImaginaireModel): The PyTorch mode
cosmos_predict2/_src/predict2/distill/checkpointer/dcp_distill.py:153
↓ 2 callersMethodsave
Save network weights, optimizer parameters, scheduler parameters to a checkpoint. Args: model (ImaginaireModel): The PyTorch mode
cosmos_predict2/_src/reason1/parallelisms/dcp_checkpointer.py:428
↓ 2 callersMethodsave_pkl
Saves a Config object to a file using pickle serialization. This method is typically used when the configuration object contains comp
cosmos_predict2/_src/imaginaire/lazy_config/lazy.py:307
↓ 2 callersMethodsave_state_dict_worker
(self, to_save_dict: Dict[str, Tuple[Any, str]], checkpoint_file: str)
cosmos_predict2/_src/predict2/checkpointer/dcp.py:700
↓ 2 callersMethodsave_state_dict_worker
(self, to_save_dict: Dict[str, Tuple[Any, str]], checkpoint_file: str)
cosmos_predict2/_src/predict2/distill/checkpointer/dcp.py:659
↓ 2 callersMethodsave_state_dict_worker
(self, to_save_dict: dict[str, tuple[Any, str]], checkpoint_file: str)
cosmos_predict2/_src/reason1/utils/dcp_checkpointer.py:441
↓ 2 callersMethodsave_state_dict_worker
(self, to_save_dict: Dict[str, Tuple[Any, str]], checkpoint_file: str)
cosmos_predict2/_src/reason1/parallelisms/dcp_checkpointer.py:410
↓ 2 callersMethodschedule
(self, n, **kwargs)
cosmos_predict2/_src/imaginaire/functional/lr_scheduler.py:60
↓ 2 callersFunctionsearch_parameter
(param, state_dict)
cosmos_predict2/_src/predict2/models/utils.py:126
↓ 2 callersMethodset_context_parallel_group
(self, process_group, ranks, stream)
cosmos_predict2/_src/predict2/networks/wan2pt1.py:378
↓ 2 callersMethodset_cp_mesh
(self, cp_mesh)
cosmos_predict2/_src/reason1/networks/qwen2_vl.py:1121
↓ 2 callersMethodset_enable
(self, enable=True)
cosmos_predict2/_src/predict2/tokenizers/wan2pt1_2d_plugins.py:125
↓ 2 callersMethodset_partial_channel_weight
(self, dcp_allow_mismatched_size: bool)
cosmos_predict2/_src/predict2/distill/checkpointer/dcp.py:145
↓ 2 callersMethodset_transforms_metadata
Set the metadata for the transforms. This is useful for transforms that need to know the metadata, such as the normalization values.
groot_dreams/data/dataset.py:534
↓ 2 callersMethodset_urls
(self, urls: list[TarSample])
cosmos_predict2/_src/imaginaire/datasets/webdataset/distributors/multi_aspect_ratio_v2.py:77
↓ 2 callersMethodshared_step
(self, batch: Dict)
external/lam/model.py:67
↓ 2 callersMethodshared_step
(self, batch: Dict)
external/lam_project/lam/model.py:54
↓ 2 callersMethodslice_generator_output
(self, G_x0_theta_B_C_T_H_W, condition)
cosmos_predict2/_src/predict2/distill/models/video2world_model_distill_dmd2.py:420
↓ 2 callersFunctionsrgb2lin
Convert sRGB values to physically linear ones. The transformation is uniform in RGB, so *srgb* can be of any shape. *srgb* values should rang
cosmos_predict2/_src/imaginaire/utils/tone_curve.py:35
↓ 2 callersMethodstate_dict
(self)
cosmos_predict2/_src/predict2/distill/checkpointer/dcp.py:299
↓ 2 callersMethodstate_dict
(self)
cosmos_predict2/_src/predict2/distill/models/distillation_base_mixin.py:842
↓ 2 callersMethodstep_inference
Runs a single inference step to generate the next video frame and the full video given an input image and action. Args:
cosmos_predict2/_src/predict2/action/inference/inference_pipeline.py:209
↓ 2 callersMethodstop_workers
Gracefully shutdown all worker processes. Performs orderly shutdown by: 1. Broadcasting shutdown command to all workers 2. Te
packages/cosmos-gradio/cosmos_gradio/model_ipc/model_server.py:137
↓ 2 callersFunctionsync_model_states
Modify based on DDP source code Synchronizes the parameters and buffers of a model across different processes in a distributed setting.
cosmos_predict2/_src/imaginaire/utils/distributed.py:351
↓ 2 callersFunctionto_dict
(x: T, field_name: str = "", hydra_compat: bool = True)
cosmos_predict2/_src/imaginaire/serialization.py:39
↓ 2 callersFunctionto_h
(T)
cosmos_predict2/_src/imaginaire/modules/camera_test.py:69
↓ 2 callersMethodto_json
(self, file_name=None)
cosmos_predict2/_src/imaginaire/utils/env_parsers/env_parser.py:97
↓ 2 callersMethodtrain
The training function. Args: model (ImaginaireModel): The PyTorch model. dataloader_train (torch.utils.data.DataLoade
cosmos_predict2/_src/imaginaire/trainer.py:149
↓ 2 callersMethodtrain
(self, training_fn)
external/lam_project/ray_launch.py:112
↓ 2 callersFunctiontrain_and_save
(model, optimizer, scheduler, grad_scaler, checkpointer)
cosmos_predict2/_src/imaginaire/checkpointer/ddp_test.py:100
↓ 2 callersMethodtraining_step
Performs a single training step for the diffusion model. This method is responsible for executing one iteration of the model's train
cosmos_predict2/_src/predict2/models/text2world_model.py:343
↓ 2 callersMethodupdate_frame
Update the current frame. Frame should be HWC, uint8, RGB.
cosmos_predict2/_src/predict2/interactive/inference/action_video2world_teleop.py:177
↓ 2 callersMethodupdate_kv_cache
Run a forward pass with ``store_kv=True`` to populate the KV cache. In stateful mode (``kv_states=None``), the cache is updated in-place on
cosmos_predict2/_src/predict2/interactive/models/action_video2world_self_forcing.py:456
↓ 2 callersFunctionupdate_master_weights
(optimizer: torch.optim.Optimizer)
cosmos_predict2/_src/predict2/distill/utils/misc.py:31
↓ 2 callersMethodvalidate
Validate if the actual answer contains the expected answer or at least one of the expected keywords. Args: actual_answer
packages/cosmos-oss/vqa/check.py:39
↓ 2 callersMethodvalidate
Validate on the full validation dataset. Args: model (ImaginaireModel): The PyTorch model. dataloader_val (torch.util
cosmos_predict2/_src/imaginaire/trainer.py:334
↓ 2 callersMethodvalidate_checkpoint_id
Validate if the checkpoint_id is a valid S3 URI.
cosmos_predict2/_src/imaginaire/checkpointer/s3_filesystem.py:220
↓ 2 callersMethodwait_for_status
(self, timeout: int = 1800)
packages/cosmos-gradio/cosmos_gradio/model_ipc/command_ipc.py:145
↓ 2 callersFunctionwhitespace_clean
(text)
cosmos_predict2/_src/predict2/inference/get_umt5_emb.py:52
↓ 2 callersMethodx0_pred
(self, trainer, model, data_batch, output_batch, loss, iteration)
cosmos_predict2/_src/predict2/callbacks/every_n_draw_sample.py:146
← previousnext →701–800 of 3,821, ranked by callers