MCPcopy Create free account

hub / github.com/Vchitect/SEINE / functions

Functions203 in github.com/Vchitect/SEINE

Method__init__
(self, channels, use_conv=False, out_channels=None, padding=1, name="conv")
models/resnet.py:80
Method__init__
( self, *, in_channels, out_channels=None, conv_shortcut=False,
models/resnet.py:114
Method__repr__
(self)
datasets/video_transforms.py:227
Method__repr__
(self)
datasets/video_transforms.py:264
Method__repr__
(self)
datasets/video_transforms.py:295
Method__repr__
(self)
datasets/video_transforms.py:320
Method__repr__
(self)
datasets/video_transforms.py:342
Method__repr__
(self)
datasets/video_transforms.py:377
Method_scale_timesteps
(self, t)
diffusion/respace.py:113
Method_set_gradient_checkpointing
(self, module, value=False)
models/unet.py:362
Functionavg_pool_nd
Create a 1D, 2D, or 3D average pooling module.
models/utils.py:161
Methodbackward
(ctx, *output_grads)
models/utils.py:54
Methodcalc_bpd_loop
Compute the entire variational lower-bound, measured in bits-per-dim, as well as other related quantities. :param model: t
diffusion/gaussian_diffusion.py:863
Functioncenter_crop_arr
Center cropping implementation from ADM. https://github.com/openai/guided-diffusion/blob/8fb3ad9197f16bbc40620447b2742e13458d2831/guided_di
datasets/video_transforms.py:17
Functioncheckpoint
Evaluate a function without caching intermediate activations, allowing for reduced memory at the expense of extra compute in the backward p
models/utils.py:25
Functioncleanup
End DDP training.
utils.py:246
Functionclip_grad_norm_
r""" Copy from torch.nn.utils.clip_grad_norm_ Clips gradient norm of an iterable of parameters. The norm is computed over all gradients
utils.py:72
Functioncollect_env
()
utils.py:336
Methodcondition_mean
(self, cond_fn, *args, **kwargs)
diffusion/respace.py:100
Methodcondition_score
(self, cond_fn, *args, **kwargs)
diffusion/respace.py:103
Functioncontinuous_gaussian_log_likelihood
Compute the log-likelihood of a continuous Gaussian distribution. :param x: the targets :param means: the Gaussian mean Tensor. :
diffusion/diffusion_utils.py:47
Functionconv_nd
Create a 1D, 2D, or 3D convolution module.
models/utils.py:141
Functioncount_flops_attn
A counter for the `thop` package to count the operations in an attention operation. Meant to be used like: macs, params = tho
models/utils.py:192
Functioncount_params
(model, verbose=False)
models/utils.py:211
Functioncreate_accelerate_logger
Create a logger that writes to a log file and stdout.
utils.py:185
Methodcreate_custom_forward
(module, return_dict=None)
models/unet_blocks.py:326
Methodcreate_custom_forward
(module)
models/unet_blocks.py:423
Methodcreate_custom_forward
(module, return_dict=None)
models/unet_blocks.py:542
Methodcreate_custom_forward
(module)
models/unet_blocks.py:634
Methodcreate_custom_forward_attn
(module, return_dict=None, use_image_num=None)
models/unet_blocks.py:335
Methodcreate_custom_forward_attn
(module, return_dict=None, use_image_num=None)
models/unet_blocks.py:551
Functioncreate_logger
Create a logger that writes to a log file and stdout.
utils.py:166
Functioncreate_named_schedule_sampler
Create a ScheduleSampler from a library of pre-defined samplers. :param name: the name of the sampler. :param diffusion: the diffusion
diffusion/timestep_sampler.py:13
Functioncreate_tensorboard
Create a tensorboard that saves losses.
utils.py:204
Methodcustom_forward
(*inputs)
models/unet_blocks.py:327
Methodcustom_forward
(*inputs)
models/unet_blocks.py:424
Methodcustom_forward
(*inputs)
models/unet_blocks.py:543
Methodcustom_forward
(*inputs)
models/unet_blocks.py:635
Methodddim_reverse_sample
Sample x_{t+1} from the model using DDIM reverse ODE.
diffusion/gaussian_diffusion.py:598
Methodencode
(self, text)
models/clip.py:57
Functionfetch_files_by_numbers
(start_number, count, file_list)
utils.py:20
Functionfn
(step)
models/__init__.py:10
Methodfn_recursive_retrieve_slicable_dims
(module: torch.nn.Module)
models/unet.py:313
Methodfn_recursive_set_attention_slice
(module: torch.nn.Module, slice_size: List[int])
models/unet.py:351
Methodforward
(self, n, device)
models/unet.py:85
Methodforward
(self, text)
models/clip.py:48
Methodforward
(self, text_prompts, train, force_drop_ids=None)
models/clip.py:83
Methodforward
(ctx, run_function, length, *args)
models/utils.py:44
Methodforward
(self, x)
models/utils.py:138
Methodforward
(self, hidden_states, temb=None, encoder_hidden_states=None, attention_mask=None, use_image_num=None)
models/unet_blocks.py:226
Methodforward
(self, hidden_states, temb=None, encoder_hidden_states=None, attention_mask=None, use_image_num=None)
models/unet_blocks.py:320
Methodforward
(self, hidden_states, temb=None)
models/unet_blocks.py:417
Methodforward
( self, hidden_states, res_hidden_states_tuple, temb=None, encoder_hid
models/unet_blocks.py:524
Methodforward
(self, hidden_states, res_hidden_states_tuple, temb=None, upsample_size=None)
models/unet_blocks.py:625
Methodforward
(self, hidden_states, encoder_hidden_states=None, attention_mask=None, use_image_num=None)
models/attention.py:155
Methodforward
(self, hidden_states, encoder_hidden_states=None, timestep=None, use_image_num=None, return_dict: bool = True)
models/attention.py:378
Methodforward
(self, hidden_states, encoder_hidden_states=None, timestep=None, attention_mask=None, video_length=None, use_i
models/attention.py:568
Methodforward
(self, hidden_states, encoder_hidden_states=None, attention_mask=None, video_length=None, use_image_num=None)
models/attention.py:771
Methodforward
(self, hidden_states, encoder_hidden_states=None, attention_mask=None)
models/attention.py:815
Methodforward
(self, n, device)
models/attention.py:962
Methodforward
(self, x)
models/resnet.py:14
Methodforward
(self, hidden_states, output_size=None)
models/resnet.py:44
Methodforward
(self, hidden_states)
models/resnet.py:102
Methodforward
(self, input_tensor, temb)
models/resnet.py:177
Methodforward_with_cfg
Forward pass of DiT, but also batches the unconditional forward pass for classifier-free guidance.
models/unet.py:513
Functionget_experiment_dir
(root_dir, args)
utils.py:147
Functionget_grad_norm
r""" Copy from torch.nn.utils.clip_grad_norm_ Clips gradient norm of an iterable of parameters. The norm is computed over all gradients
utils.py:35
Functionget_lr_scheduler
(optimizer, name, **kwargs)
models/__init__.py:18
Functionget_named_beta_schedule
Get a pre-defined beta schedule for the given name. The beta schedule library consists of beta schedules which remain similar in the l
diffusion/gaussian_diffusion.py:98
Functionhflip
Args: clip (torch.tensor): Video clip to be normalized. Size is (T, C, H, W) Returns: flipped clip (torch.tensor): Size i
datasets/video_transforms.py:182
Methodis_vb
(self)
diffusion/gaussian_diffusion.py:54
Functionlinear
Create a linear module.
models/utils.py:154
Functionmean_flat
Take the mean over all non-batch dimensions.
models/utils.py:115
Functionnoise_like
(shape, device, repeat=False)
models/utils.py:187
Functionnormalization
Make a standard normalization layer. :param channels: number of input channels. :return: an nn.Module for normalization.
models/utils.py:122
Methodp_mean_variance
( self, model, *args, **kwargs )
diffusion/respace.py:89
Methodprocess_xstart
(x)
diffusion/gaussian_diffusion.py:322
Functionrandom_shift_crop
Slide along the long edge, with the short edge as crop size
datasets/video_transforms.py:124
Functionrequires_grad
Set requires_grad flag for all parameters in a model.
utils.py:239
Methodreshape_for_scores
(self, tensor)
models/attention.py:135
Functionresize_scale
(clip, target_size, interpolation_mode)
datasets/video_transforms.py:53
Functionresize_scale_with_height
(clip, target_size, interpolation_mode)
datasets/video_transforms.py:63
Functionresize_scale_with_weight
(clip, target_size, interpolation_mode)
datasets/video_transforms.py:68
Functionresize_with_scale_factor
(clip, scale_factor, interpolation_mode)
datasets/video_transforms.py:60
Functionresized_crop
Do spatial cropping and resizing to the video clip Args: clip (torch.tensor): Video clip to be cropped. Size is (T, C, H, W)
datasets/video_transforms.py:74
Methodsame_batch_dim_to_heads
(self, tensor)
models/attention.py:144
Functionsave_video_grid
(video, nrow=None)
utils.py:292
Functionsave_videos_grid_tav
(videos: torch.Tensor, path: str, rescale=False, n_rows=4, fps=8)
utils.py:312
Functionscale_module
Scale the parameters of a module and return it.
models/utils.py:106
Functionseparation_content_motion
separate coontent and motion in a given video Args: video_clip, a give video clip, [B F C H W] Return: base frame, [B, 1
utils.py:129
Methodset_attention_slice
(self, slice_size)
models/attention.py:149
Methodset_use_memory_efficient_attention_xformers
(self, use_memory_efficient_attention_xformers: bool, op=None)
models/attention.py:538
Functionsetup_distributed
Initialize distributed training environment. support both slurm and torch.distributed.launch see torch.distributed.init_process_group() for mo
utils.py:253
Functiontimestep_embedding
Create sinusoidal timestep embeddings. :param timesteps: a 1-D Tensor of N indices, one per batch element. These may
models/utils.py:74
Methodtraining_losses
Compute training losses for a single timestep. :param model: the model to evaluate loss on. :param x_start: the [N x C x .
diffusion/gaussian_diffusion.py:763
Methodtraining_losses
( self, model, *args, **kwargs )
diffusion/respace.py:95
Functionupdate_ema
Step the EMA model towards the current model.
utils.py:227
Methodupdate_with_all_losses
(self, ts, losses)
diffusion/timestep_sampler.py:139
Methodupdate_with_local_losses
Update the reweighting using losses from a model. Call this method from each rank with a batch of timesteps and the corres
diffusion/timestep_sampler.py:72
Methodweights
(self)
diffusion/timestep_sampler.py:67
← previousnext →101–200 of 203, ranked by callers