MCPcopy Create free account

hub / github.com/JaydenLyh/Reward-Forcing / functions

Functions579 in github.com/JaydenLyh/Reward-Forcing

↓ 1 callersFunctionload_configs_from_json
(config_path)
videoalign/inference.py:22
↓ 1 callersFunctionload_configs_from_json
(config_path)
videoalign/wan_inference.py:22
↓ 1 callersFunctionload_video_frames
(video_path, num_frames=81)
videoalign/wan_inference.py:291
↓ 1 callersFunctionmain
()
train.py:9
↓ 1 callersFunctionmain
Run TAEHV roundtrip reconstruction on the given video paths.
demo_utils/taehv.py:241
↓ 1 callersFunctionmain
Aggregate all ode pairs inside a folder into a lmdb dataset. Each pt file should contain a (key, value) pair representing a video's ODE t
scripts/create_lmdb_iterative.py:12
↓ 1 callersFunctionmain
()
scripts/generate_ode_pairs.py:32
↓ 1 callersFunctionmain
Aggregate all ode pairs inside a folder into a lmdb dataset. Each pt file should contain a (key, value) pair representing a video's ODE t
scripts/create_lmdb_14b_shards.py:17
↓ 1 callersFunctionmove_model_to_device_with_memory_preservation
(model, target_device, preserved_memory_gb=0)
demo_utils/memory.py:85
↓ 1 callersMethodmultistep_dpm_solver_second_order_update
One step for the second-order multistep DPMSolver. Args: model_output_list (`List[torch.Tensor]`): The di
wan/utils/fm_solvers.py:486
↓ 1 callersMethodmultistep_dpm_solver_third_order_update
One step for the third-order multistep DPMSolver. Args: model_output_list (`List[torch.Tensor]`): The dir
wan/utils/fm_solvers.py:596
↓ 1 callersMethodmultistep_uni_c_bh_update
One step for the UniC (B(h) version). Args: this_model_output (`torch.Tensor`): The model outputs at `x_
wan/utils/fm_solvers_unipc.py:486
↓ 1 callersMethodmultistep_uni_p_bh_update
One step for the UniP (B(h) version). Alternatively, `self.solver_p` is used if is specified. Args: model_output (`torch
wan/utils/fm_solvers_unipc.py:350
↓ 1 callersFunctionpad_freqs
(original_tensor, target_len)
wan/distributed/xdit_context_parallel.py:12
↓ 1 callersMethodpatch_tgrow_layers
Patch TGrow layers to use a smaller kernel if needed. Args: sd: state dict to patch
demo_utils/taehv.py:195
↓ 1 callersFunctionpos_interpolate
(pos, seq_len)
wan/modules/clip.py:22
↓ 1 callersMethodpost_init
A few custom initialization steps that should be called after the object is created. Currently, the only one we have is to bind a few
utils/wan_wrapper.py:307
↓ 1 callersMethodprepare_batch
(self, video_paths, prompts, fps=None, num_frames=None, max_pixels=None,)
videoalign/inference.py:188
↓ 1 callersMethodprepare_batch
(self, video_paths, prompts, fps=None, num_frames=None, max_pixels=None,)
videoalign/wan_inference.py:187
↓ 1 callersMethodprepare_batch_from_frames
直接从帧张量准备batch(跳过视频文件加载) Args: video_tensors: List[torch.Tensor], 每个张量形状为 [T, C, H, W] prompts: List[str], 提示文
videoalign/inference.py:126
↓ 1 callersMethodprepare_batch_from_frames
Args: video_tensors: List[torch.Tensor], shape [T, C, H, W] prompts: List[str]
videoalign/wan_inference.py:126
↓ 1 callersFunctionrand_name
(length=8, suffix='')
wan/utils/utils.py:14
↓ 1 callersMethodread_calibration_cache
(self)
demo_utils/vae_torch2trt.py:202
↓ 1 callersMethodreward
Inputs: video_paths: List[str], B paths of the videos. prompts: List[str], B prompts for the videos. eval
videoalign/wan_inference.py:241
↓ 1 callersMethodreward_from_frames
(self, video_tensors, prompts, use_norm=True)
videoalign/inference.py:164
↓ 1 callersMethodreward_from_frames
(self, video_tensors, prompts, use_norm=True)
videoalign/wan_inference.py:165
↓ 1 callersMethodsample
(self, imgs, deterministic=False)
wan/modules/vae.py:595
↓ 1 callersMethodsave
(self)
trainer/distillation.py:189
↓ 1 callersMethodsave
(self)
trainer/diffusion.py:140
↓ 1 callersMethodsave
(self)
trainer/gan.py:208
↓ 1 callersMethodsave
(self)
trainer/rewarded_distillation.py:191
↓ 1 callersFunctionsave_configs_to_json
Save all configurations to a JSON file.
videoalign/train_reward.py:21
↓ 1 callersMethodstep
Predict the sample from the previous timestep by reversing the SDE. This function propagates the sample with the multistep UniPC.
wan/utils/fm_solvers_unipc.py:655
↓ 1 callersMethodtemporal_conv
(self, x, is_first_frame, feat_cache)
demo_utils/vae.py:105
↓ 1 callersMethodtime_shift
(self, mu: float, sigma: float, t: torch.Tensor)
wan/utils/fm_solvers.py:337
↓ 1 callersMethodtime_shift
(self, mu: float, sigma: float, t: torch.Tensor)
wan/utils/fm_solvers_unipc.py:276
↓ 1 callersFunctiontrain
()
videoalign/train_reward.py:164
↓ 1 callersMethodtrain_one_step
(self, batch)
trainer/diffusion.py:163
↓ 1 callersMethodtrain_one_step
(self)
trainer/ode.py:134
↓ 1 callersMethodtraining_target
(self, sample, noise, timestep)
utils/scheduler.py:178
↓ 1 callersMethodtraining_weight
Input: - timestep: the timestep with shape [B*T] Output: the corresponding weighting [B*T]
utils/scheduler.py:182
↓ 1 callersFunctionunload_complete_models
(*args)
demo_utils/memory.py:117
↓ 1 callersMethodwrite_calibration_cache
(self, cache)
demo_utils/vae_torch2trt.py:212
Method__call__
Preprocess inputs to token sequences and return a batch
videoalign/data.py:187
Method__call__
Base class for denoising loss. Input: - x: the clean data with shape [B, F, C, H, W] - x_pred: the predicted
utils/loss.py:7
Method__call__
( self, x: torch.Tensor, x_pred: torch.Tensor, noise: torch.Tensor, noise_pred: torch.Tensor,
utils/loss.py:28
Method__call__
( self, x: torch.Tensor, x_pred: torch.Tensor, noise: torch.Tensor, noise_pred: torch.Tensor,
utils/loss.py:39
Method__call__
( self, x: torch.Tensor, x_pred: torch.Tensor, noise: torch.Tensor, noise_pred: torch.Tensor,
utils/loss.py:51
Method__call__
( self, x: torch.Tensor, x_pred: torch.Tensor, noise: torch.Tensor, noise_pred: torch.Tensor,
utils/loss.py:62
Method__call__
(self, sequence, **kwargs)
wan/modules/tokenizers.py:49
Method__call__
(self, texts, device)
wan/modules/t5.py:506
Method__call__
(self, prompt, tar_lang="ch", image=None,
wan/utils/prompt_extend.py:138
Method__del__
(self)
demo_utils/taehv.py:273
Method__getitem__
(self, idx)
utils/dataset.py:27
Method__getitem__
Outputs: - prompts: List of Strings - latents: Tensor of shape (num_denoising_steps, num_frames, num_channels, height
utils/dataset.py:48
Method__getitem__
Outputs: - prompts: List of Strings - latents: Tensor of shape (num_denoising_steps, num_frames, num_chan
utils/dataset.py:99
Method__getitem__
Returns: dict: A dictionary containing: - image: PIL Image - caption: str - targe
utils/dataset.py:185
Method__init__
(self, processor, add_noise=False, p_shuffle_frames=0.0, p_color_jitter=0.0)
videoalign/data.py:132
Method__init__
(self, load_from_pretrained, load_from_pretrained_step=-1, device='cuda', dtype=torch.bfloat16)
videoalign/inference.py:34
Method__init__
(self, special_token_ids)
videoalign/trainer.py:224
Method__init__
(self, loss_type="regular", enable_noise_in_eval=False, *args, **kwargs)
videoalign/trainer.py:246
Method__init__
(self, load_from_pretrained, load_from_pretrained_step=-1, device='cuda', dtype=torch.bfloat16)
videoalign/wan_inference.py:34
Method__init__
(self, num_inference_steps=100, num_train_timesteps=1000, shift=3.0, sigma_max=1.0, sigma_min=0.003 / 1.002, i
utils/scheduler.py:108
Method__init__
(self, fsdp_module: torch.nn.Module, decay: float = 0.999)
utils/distributed.py:92
Method__init__
(self, prompt_path, extended_prompt_path=None)
utils/dataset.py:13
Method__init__
(self, data_path: str, max_pair: int = int(1e8))
utils/dataset.py:38
Method__init__
(self, data_path: str, max_pair: int = int(1e8))
utils/dataset.py:73
Method__init__
Args: data_dir (str): Path to the directory containing: - target_crop_info_*.json (metadata file)
utils/dataset.py:128
Method__init__
(self, checkpoint_path)
utils/wan_wrapper.py:15
Method__init__
( self, checkpoint_path, model_name="Wan2.1-T2V-1.3B", timeste
utils/wan_wrapper.py:117
Method__init__
r""" Initializes the image-to-video generation model components. Args: config (EasyDict): Object containi
wan/image2video.py:31
Method__init__
r""" Initializes the Wan text-to-video generation model components. Args: config (EasyDict): Object conta
wan/text2video.py:28
Method__init__
(self, dim, num_heads, local_attn_size=-1,
wan/modules/causal_model.py:60
Method__init__
(self, cross_attn_type, dim, ffn_dim, num_
wan/modules/causal_model.py:265
Method__init__
r""" Initialize the diffusion model backbone. Args: model_type (`str`, *optional*, defaults to 't2v'): Mo
wan/modules/causal_model.py:401
Method__init__
(self, name, seq_len=None, clean=None, **kwargs)
wan/modules/tokenizers.py:39
Method__init__
(self, dim, num_heads, causal=False, attn_
wan/modules/clip.py:55
Method__init__
(self, dim, mlp_ratio, num_heads, post_nor
wan/modules/clip.py:114
Method__init__
(self, dim, mlp_ratio, num_heads, activati
wan/modules/clip.py:158
Method__init__
(self, image_size=224, patch_size=16, dim=768,
wan/modules/clip.py:211
Method__init__
(self, **kwargs)
wan/modules/clip.py:305
Method__init__
(self, embed_dim=1024, image_size=224, patch_size=14,
wan/modules/clip.py:330
Method__init__
(self, dtype, device, checkpoint_path, tokenizer_path)
wan/modules/clip.py:503
Method__init__
(self, dim, eps=1e-6)
wan/modules/t5.py:55
Method__init__
(self, dim, dim_attn, num_heads, dropout=0.1)
wan/modules/t5.py:71
Method__init__
(self, dim, dim_ffn, dropout=0.1)
wan/modules/t5.py:125
Method__init__
(self, dim, dim_attn, dim_ffn, num_heads,
wan/modules/t5.py:146
Method__init__
(self, dim, dim_attn, dim_ffn, num_heads,
wan/modules/t5.py:180
Method__init__
(self, num_buckets, num_heads, bidirectional, max_dist=128)
wan/modules/t5.py:223
Method__init__
(self, vocab, dim, dim_attn, dim_ffn,
wan/modules/t5.py:269
Method__init__
(self, vocab, dim, dim_attn, dim_ffn,
wan/modules/t5.py:317
Method__init__
( self, text_len, dtype=torch.bfloat16, device=torch.cuda.current_device(),
wan/modules/t5.py:474
Method__init__
(self, *args, **kwargs)
wan/modules/vae.py:22
Method__init__
(self, dim, channel_first=True, images=True, bias=False)
wan/modules/vae.py:41
Method__init__
(self, dim, mode)
wan/modules/vae.py:68
Method__init__
(self, in_dim, out_dim, dropout=0.0)
wan/modules/vae.py:188
Method__init__
(self, dim)
wan/modules/vae.py:228
Method__init__
(self, dim=128, z_dim=4, dim_mult=[1, 2, 4, 4],
wan/modules/vae.py:267
Method__init__
(self, dim=128, z_dim=4, dim_mult=[1, 2, 4, 4],
wan/modules/vae.py:371
Method__init__
(self, dim=128, z_dim=4, dim_mult=[1, 2, 4, 4],
wan/modules/vae.py:485
← previousnext →201–300 of 579, ranked by callers