SYMBOL INDEX (700 symbols across 29 files) FILE: app.py class FoleyController (line 55) | class FoleyController: method __init__ (line 56) | def __init__(self): method load_model (line 70) | def load_model(self): method foley (line 127) | def foley( FILE: foleycrafter/data/dataset.py function zero_rank_print (line 14) | def zero_rank_print(s): function get_mel (line 20) | def get_mel(audio_data, audio_cfg): function dynamic_range_compression (line 42) | def dynamic_range_compression(x, normalize_fun=torch.log, C=1, clip_val=... class CPU_Unpickler (line 51) | class CPU_Unpickler(pickle.Unpickler): method find_class (line 52) | def find_class(self, module, name): class AudioSetStrong (line 59) | class AudioSetStrong(Dataset): method __init__ (line 61) | def __init__( method get_batch (line 79) | def get_batch(self, idx): method __len__ (line 94) | def __len__(self): method __getitem__ (line 97) | def __getitem__(self, idx): class VGGSound (line 115) | class VGGSound(Dataset): method __init__ (line 117) | def __init__( method get_batch (line 129) | def get_batch(self, idx): method __len__ (line 143) | def __len__(self): method __getitem__ (line 146) | def __getitem__(self, idx): FILE: foleycrafter/data/video_transforms.py function _is_tensor_video_clip (line 7) | def _is_tensor_video_clip(clip): function crop (line 17) | def crop(clip, i, j, h, w): function resize (line 27) | def resize(clip, target_size, interpolation_mode): function resize_scale (line 33) | def resize_scale(clip, target_size, interpolation_mode): function resized_crop (line 41) | def resized_crop(clip, i, j, h, w, size, interpolation_mode="bilinear"): function center_crop (line 61) | def center_crop(clip, crop_size): function random_shift_crop (line 74) | def random_shift_crop(clip): function to_tensor (line 96) | def to_tensor(clip): function normalize (line 112) | def normalize(clip, mean, std, inplace=False): function hflip (line 132) | def hflip(clip): class RandomCropVideo (line 144) | class RandomCropVideo: method __init__ (line 145) | def __init__(self, size): method __call__ (line 151) | def __call__(self, clip): method get_params (line 162) | def get_params(self, clip): method __repr__ (line 177) | def __repr__(self) -> str: class UCFCenterCropVideo (line 181) | class UCFCenterCropVideo: method __init__ (line 182) | def __init__( method __call__ (line 196) | def __call__(self, clip): method __repr__ (line 208) | def __repr__(self) -> str: class KineticsRandomCropResizeVideo (line 212) | class KineticsRandomCropResizeVideo: method __init__ (line 217) | def __init__( method __call__ (line 231) | def __call__(self, clip): class CenterCropVideo (line 237) | class CenterCropVideo: method __init__ (line 238) | def __init__( method __call__ (line 252) | def __call__(self, clip): method __repr__ (line 263) | def __repr__(self) -> str: class NormalizeVideo (line 267) | class NormalizeVideo: method __init__ (line 276) | def __init__(self, mean, std, inplace=False): method __call__ (line 281) | def __call__(self, clip): method __repr__ (line 288) | def __repr__(self) -> str: class ToTensorVideo (line 292) | class ToTensorVideo: method __init__ (line 298) | def __init__(self): method __call__ (line 301) | def __call__(self, clip): method __repr__ (line 310) | def __repr__(self) -> str: class RandomHorizontalFlipVideo (line 314) | class RandomHorizontalFlipVideo: method __init__ (line 321) | def __init__(self, p=0.5): method __call__ (line 324) | def __call__(self, clip): method __repr__ (line 335) | def __repr__(self) -> str: class TemporalRandomCrop (line 342) | class TemporalRandomCrop(object): method __init__ (line 349) | def __init__(self, size): method __call__ (line 352) | def __call__(self, total_frames): FILE: foleycrafter/models/adapters/attention_processor.py class AttnProcessor (line 11) | class AttnProcessor(nn.Module): method __init__ (line 16) | def __init__( method __call__ (line 23) | def __call__( class IPAttnProcessor (line 84) | class IPAttnProcessor(nn.Module): method __init__ (line 98) | def __init__(self, hidden_size, cross_attention_dim=None, scale=1.0, n... method __call__ (line 109) | def __call__( class AttnProcessor2_0 (line 191) | class AttnProcessor2_0(torch.nn.Module): method __init__ (line 196) | def __init__( method __call__ (line 205) | def __call__( class AttnProcessor2_0WithProjection (line 280) | class AttnProcessor2_0WithProjection(torch.nn.Module): method __init__ (line 285) | def __init__( method __call__ (line 297) | def __call__( class IPAttnProcessor2_0 (line 373) | class IPAttnProcessor2_0(torch.nn.Module): method __init__ (line 387) | def __init__(self, hidden_size, cross_attention_dim=None, scale=1.0, n... method __call__ (line 401) | def __call__( class CNAttnProcessor (line 505) | class CNAttnProcessor: method __init__ (line 510) | def __init__(self, num_tokens=4): method __call__ (line 513) | def __call__(self, attn, hidden_states, encoder_hidden_states=None, at... class CNAttnProcessor2_0 (line 570) | class CNAttnProcessor2_0: method __init__ (line 575) | def __init__(self, num_tokens=4): method __call__ (line 580) | def __call__( FILE: foleycrafter/models/adapters/ip_adapter.py class IPAdapter (line 5) | class IPAdapter(torch.nn.Module): method __init__ (line 8) | def __init__(self, unet, image_proj_model, adapter_modules, ckpt_path=... method forward (line 17) | def forward(self, noisy_latents, timesteps, encoder_hidden_states, ima... method load_from_checkpoint (line 24) | def load_from_checkpoint(self, ckpt_path: str): class ImageProjModel (line 46) | class ImageProjModel(torch.nn.Module): method __init__ (line 49) | def __init__(self, cross_attention_dim=1024, clip_embeddings_dim=1024,... method forward (line 57) | def forward(self, image_embeds): class MLPProjModel (line 66) | class MLPProjModel(torch.nn.Module): method zero_initialize (line 69) | def zero_initialize(module): method zero_initialize_last_layer (line 73) | def zero_initialize_last_layer(module): method __init__ (line 83) | def __init__(self, cross_attention_dim=1024, clip_embeddings_dim=1024): method forward (line 95) | def forward(self, image_embeds): class V2AMapperMLP (line 100) | class V2AMapperMLP(torch.nn.Module): method __init__ (line 101) | def __init__(self, cross_attention_dim=512, clip_embeddings_dim=512, m... method forward (line 110) | def forward(self, image_embeds): class TimeProjModel (line 115) | class TimeProjModel(torch.nn.Module): method __init__ (line 116) | def __init__(self, positive_len, out_dim, feature_type="text-only", fr... method forward (line 156) | def forward( FILE: foleycrafter/models/adapters/resampler.py function FeedForward (line 13) | def FeedForward(dim, mult=4): function reshape_tensor (line 23) | def reshape_tensor(x, heads): class PerceiverAttention (line 34) | class PerceiverAttention(nn.Module): method __init__ (line 35) | def __init__(self, *, dim, dim_head=64, heads=8): method forward (line 49) | def forward(self, x, latents): class Resampler (line 81) | class Resampler(nn.Module): method __init__ (line 82) | def __init__( method forward (line 127) | def forward(self, x): function masked_mean (line 150) | def masked_mean(t, *, dim, mask=None): FILE: foleycrafter/models/adapters/transformer.py class Attention (line 8) | class Attention(nn.Module): method __init__ (line 11) | def __init__(self, hidden_size, num_attention_heads, attention_head_di... method _shape (line 27) | def _shape(self, tensor: torch.Tensor, seq_len: int, bsz: int): method forward (line 30) | def forward( class MLP (line 109) | class MLP(nn.Module): method __init__ (line 110) | def __init__(self, hidden_size, intermediate_size, mult=4): method forward (line 116) | def forward(self, hidden_states: torch.Tensor) -> torch.Tensor: class Transformer (line 123) | class Transformer(nn.Module): method __init__ (line 124) | def __init__(self, depth=12): method forward (line 128) | def forward( class TransformerBlock (line 156) | class TransformerBlock(nn.Module): method __init__ (line 157) | def __init__( method forward (line 175) | def forward( class DiffusionTransformerBlock (line 216) | class DiffusionTransformerBlock(nn.Module): method __init__ (line 217) | def __init__( method forward (line 236) | def forward( class V2AMapperMLP (line 279) | class V2AMapperMLP(nn.Module): method __init__ (line 280) | def __init__(self, input_dim=512, output_dim=512, expansion_rate=4): method forward (line 287) | def forward(self, x): class ImageProjModel (line 296) | class ImageProjModel(torch.nn.Module): method __init__ (line 299) | def __init__(self, cross_attention_dim=1024, clip_embeddings_dim=1024,... method zero_initialize_last_layer (line 309) | def zero_initialize_last_layer(module): method forward (line 319) | def forward(self, image_embeds): class VisionAudioAdapter (line 328) | class VisionAudioAdapter(torch.nn.Module): method __init__ (line 329) | def __init__( method forward (line 349) | def forward(self, image_embeds): FILE: foleycrafter/models/adapters/utils.py function hook_fn (line 10) | def hook_fn(name): function register_cross_attention_hook (line 19) | def register_cross_attention_hook(unet): function upscale (line 27) | def upscale(attn_map, target_size): function get_net_attn_map (line 50) | def get_net_attn_map(image_size, batch_size=2, instance_or_negative=Fals... function attnmaps2images (line 65) | def attnmaps2images(net_attn_maps): function is_torch2_available (line 85) | def is_torch2_available(): FILE: foleycrafter/models/auffusion/attention.py function _chunked_feed_forward (line 29) | def _chunked_feed_forward( class GatedSelfAttentionDense (line 55) | class GatedSelfAttentionDense(nn.Module): method __init__ (line 66) | def __init__(self, query_dim: int, context_dim: int, n_heads: int, d_h... method forward (line 83) | def forward(self, x: torch.Tensor, objs: torch.Tensor) -> torch.Tensor: class BasicTransformerBlock (line 97) | class BasicTransformerBlock(nn.Module): method __init__ (line 132) | def __init__( method set_chunk_feed_forward (line 279) | def set_chunk_feed_forward(self, chunk_size: Optional[int], dim: int =... method forward (line 284) | def forward( class TemporalBasicTransformerBlock (line 408) | class TemporalBasicTransformerBlock(nn.Module): method __init__ (line 420) | def __init__( method set_chunk_feed_forward (line 474) | def set_chunk_feed_forward(self, chunk_size: Optional[int], **kwargs): method forward (line 480) | def forward( class SkipFFTransformerBlock (line 538) | class SkipFFTransformerBlock(nn.Module): method __init__ (line 539) | def __init__( method forward (line 581) | def forward(self, hidden_states, encoder_hidden_states, cross_attentio... class FeedForward (line 610) | class FeedForward(nn.Module): method __init__ (line 624) | def __init__( method forward (line 661) | def forward(self, hidden_states: torch.Tensor, scale: float = 1.0) -> ... FILE: foleycrafter/models/auffusion/attention_processor.py class Attention (line 40) | class Attention(nn.Module): method __init__ (line 91) | def __init__( method set_use_memory_efficient_attention_xformers (line 216) | def set_use_memory_efficient_attention_xformers( method set_attention_slice (line 350) | def set_attention_slice(self, slice_size: int) -> None: method set_processor (line 378) | def set_processor(self, processor: "AttnProcessor", _remove_lora: bool... method get_processor (line 413) | def get_processor(self, return_deprecated_lora: bool = False) -> "Atte... method forward (line 503) | def forward( method batch_to_head_dim (line 537) | def batch_to_head_dim(self, tensor: torch.Tensor) -> torch.Tensor: method head_to_batch_dim (line 554) | def head_to_batch_dim(self, tensor: torch.Tensor, out_dim: int = 3) ->... method get_attention_scores (line 577) | def get_attention_scores( method prepare_attention_mask (line 624) | def prepare_attention_mask( method norm_encoder_hidden_states (line 671) | def norm_encoder_hidden_states(self, encoder_hidden_states: torch.Tens... method fuse_projections (line 701) | def fuse_projections(self, fuse=True): class AttnProcessor (line 727) | class AttnProcessor: method __call__ (line 732) | def __call__( class CustomDiffusionAttnProcessor (line 796) | class CustomDiffusionAttnProcessor(nn.Module): method __init__ (line 815) | def __init__( method __call__ (line 841) | def __call__( class AttnAddedKVProcessor (line 900) | class AttnAddedKVProcessor: method __call__ (line 906) | def __call__( class AttnAddedKVProcessor2_0 (line 964) | class AttnAddedKVProcessor2_0: method __init__ (line 970) | def __init__(self): method __call__ (line 976) | def __call__( class XFormersAttnAddedKVProcessor (line 1037) | class XFormersAttnAddedKVProcessor: method __init__ (line 1049) | def __init__(self, attention_op: Optional[Callable] = None): method __call__ (line 1052) | def __call__( class XFormersAttnProcessor (line 1108) | class XFormersAttnProcessor: method __init__ (line 1120) | def __init__(self, attention_op: Optional[Callable] = None): method __call__ (line 1123) | def __call__( class AttnProcessor2_0 (line 1199) | class AttnProcessor2_0: method __init__ (line 1204) | def __init__(self): method __call__ (line 1208) | def __call__( class FusedAttnProcessor2_0 (line 1285) | class FusedAttnProcessor2_0: method __init__ (line 1298) | def __init__(self): method __call__ (line 1304) | def __call__( class CustomDiffusionXFormersAttnProcessor (line 1382) | class CustomDiffusionXFormersAttnProcessor(nn.Module): method __init__ (line 1405) | def __init__( method __call__ (line 1433) | def __call__( class CustomDiffusionAttnProcessor2_0 (line 1498) | class CustomDiffusionAttnProcessor2_0(nn.Module): method __init__ (line 1518) | def __init__( method __call__ (line 1544) | def __call__( class SlicedAttnProcessor (line 1612) | class SlicedAttnProcessor: method __init__ (line 1622) | def __init__(self, slice_size: int): method __call__ (line 1625) | def __call__( class SlicedAttnAddedKVProcessor (line 1699) | class SlicedAttnAddedKVProcessor: method __init__ (line 1709) | def __init__(self, slice_size): method __call__ (line 1712) | def __call__( class SpatialNorm (line 1791) | class SpatialNorm(nn.Module): method __init__ (line 1802) | def __init__( method forward (line 1812) | def forward(self, f: torch.FloatTensor, zq: torch.FloatTensor) -> torc... class LoRAAttnProcessor (line 1821) | class LoRAAttnProcessor(nn.Module): method __init__ (line 1838) | def __init__( method __call__ (line 1872) | def __call__(self, attn: Attention, hidden_states: torch.FloatTensor, ... class LoRAAttnProcessor2_0 (line 1893) | class LoRAAttnProcessor2_0(nn.Module): method __init__ (line 1911) | def __init__( method __call__ (line 1947) | def __call__(self, attn: Attention, hidden_states: torch.FloatTensor, ... class LoRAXFormersAttnProcessor (line 1968) | class LoRAXFormersAttnProcessor(nn.Module): method __init__ (line 1990) | def __init__( method __call__ (line 2026) | def __call__(self, attn: Attention, hidden_states: torch.FloatTensor, ... class LoRAAttnAddedKVProcessor (line 2047) | class LoRAAttnAddedKVProcessor(nn.Module): method __init__ (line 2065) | def __init__( method __call__ (line 2085) | def __call__(self, attn: Attention, hidden_states: torch.FloatTensor, ... class IPAdapterAttnProcessor (line 2106) | class IPAdapterAttnProcessor(nn.Module): method __init__ (line 2121) | def __init__(self, hidden_size, cross_attention_dim=None, num_tokens=4... method __call__ (line 2132) | def __call__( class VPTemporalAdapterAttnProcessor2_0 (line 2216) | class VPTemporalAdapterAttnProcessor2_0(torch.nn.Module): method __init__ (line 2238) | def __init__(self, hidden_size, cross_attention_dim=None, num_tokens=(... method __call__ (line 2266) | def __call__( class IPAdapterAttnProcessor2_0 (line 2450) | class IPAdapterAttnProcessor2_0(torch.nn.Module): method __init__ (line 2465) | def __init__(self, hidden_size, cross_attention_dim=None, num_tokens=(... method __call__ (line 2492) | def __call__( FILE: foleycrafter/models/auffusion/dual_transformer_2d.py class DualTransformer2DModel (line 21) | class DualTransformer2DModel(nn.Module): method __init__ (line 48) | def __init__( method forward (line 97) | def forward( FILE: foleycrafter/models/auffusion/loaders/ip_adapter.py class IPAdapterMixin (line 51) | class IPAdapterMixin: method load_ip_adapter (line 55) | def load_ip_adapter( method set_ip_adapter_scale (line 235) | def set_ip_adapter_scale(self, scale): method unload_ip_adapter (line 257) | def unload_ip_adapter(self): class VPAdapterMixin (line 289) | class VPAdapterMixin: method load_ip_adapter (line 293) | def load_ip_adapter( method set_ip_adapter_scale (line 473) | def set_ip_adapter_scale(self, scale): method unload_ip_adapter (line 495) | def unload_ip_adapter(self): FILE: foleycrafter/models/auffusion/loaders/unet.py class VPAdapterImageProjection (line 53) | class VPAdapterImageProjection(nn.Module): method __init__ (line 54) | def __init__(self, IPAdapterImageProjectionLayers: Union[List[nn.Modul... method forward (line 58) | def forward(self, image_embeds: List[torch.FloatTensor]): class MultiIPAdapterImageProjection (line 88) | class MultiIPAdapterImageProjection(nn.Module): method __init__ (line 89) | def __init__(self, IPAdapterImageProjectionLayers: Union[List[nn.Modul... method forward (line 93) | def forward(self, image_embeds: List[torch.FloatTensor]): class UNet2DConditionLoadersMixin (line 132) | class UNet2DConditionLoadersMixin: method load_attn_procs (line 141) | def load_attn_procs(self, pretrained_model_name_or_path_or_dict: Union... method convert_state_dict_legacy_attn_format (line 454) | def convert_state_dict_legacy_attn_format(self, state_dict, network_al... method save_attn_procs (line 481) | def save_attn_procs( method fuse_lora (line 583) | def fuse_lora(self, lora_scale=1.0, safe_fusing=False, adapter_names=N... method _fuse_lora_apply (line 588) | def _fuse_lora_apply(self, module, adapter_names=None): method unfuse_lora (line 600) | def unfuse_lora(self): method _unfuse_lora_apply (line 603) | def _unfuse_lora_apply(self, module): method set_adapters (line 608) | def set_adapters( method disable_lora (line 656) | def disable_lora(self): method enable_lora (line 679) | def enable_lora(self): method delete_adapters (line 702) | def delete_adapters(self, adapter_names: Union[List[str], str]): method _convert_ip_adapter_image_proj_to_diffusers (line 738) | def _convert_ip_adapter_image_proj_to_diffusers(self, state_dict, low_... method _convert_ip_adapter_attn_to_diffusers_VPAdapter (line 786) | def _convert_ip_adapter_attn_to_diffusers_VPAdapter(self, state_dicts,... method _convert_ip_adapter_attn_to_diffusers (line 873) | def _convert_ip_adapter_attn_to_diffusers(self, state_dicts, low_cpu_m... method _load_ip_adapter_weights (line 958) | def _load_ip_adapter_weights(self, state_dicts, low_cpu_mem_usage=False): method _load_ip_adapter_weights_VPAdapter (line 975) | def _load_ip_adapter_weights_VPAdapter(self, state_dicts, low_cpu_mem_... FILE: foleycrafter/models/auffusion/resnet.py class ResnetBlock2D (line 45) | class ResnetBlock2D(nn.Module): method __init__ (line 76) | def __init__( method forward (line 183) | def forward( function rearrange_dims (line 265) | def rearrange_dims(tensor: torch.Tensor) -> torch.Tensor: class Conv1dBlock (line 276) | class Conv1dBlock(nn.Module): method __init__ (line 288) | def __init__( method forward (line 302) | def forward(self, inputs: torch.Tensor) -> torch.Tensor: class ResidualTemporalBlock1D (line 312) | class ResidualTemporalBlock1D(nn.Module): method __init__ (line 324) | def __init__( method forward (line 343) | def forward(self, inputs: torch.Tensor, t: torch.Tensor) -> torch.Tensor: class TemporalConvLayer (line 359) | class TemporalConvLayer(nn.Module): method __init__ (line 370) | def __init__( method forward (line 411) | def forward(self, hidden_states: torch.Tensor, num_frames: int = 1) ->... class TemporalResnetBlock (line 430) | class TemporalResnetBlock(nn.Module): method __init__ (line 442) | def __init__( method forward (line 496) | def forward(self, input_tensor: torch.FloatTensor, temb: torch.FloatTe... class SpatioTemporalResBlock (line 523) | class SpatioTemporalResBlock(nn.Module): method __init__ (line 541) | def __init__( method forward (line 574) | def forward( class AlphaBlender (line 607) | class AlphaBlender(nn.Module): method __init__ (line 621) | def __init__( method get_alpha (line 641) | def get_alpha(self, image_only_indicator: torch.Tensor, ndims: int) ->... method forward (line 672) | def forward( FILE: foleycrafter/models/auffusion/transformer_2d.py class Transformer2DModelOutput (line 31) | class Transformer2DModelOutput(BaseOutput): class Transformer2DModel (line 44) | class Transformer2DModel(ModelMixin, ConfigMixin): method __init__ (line 75) | def __init__( method _set_gradient_checkpointing (line 242) | def _set_gradient_checkpointing(self, module, value=False): method forward (line 246) | def forward( FILE: foleycrafter/models/auffusion/unet_2d_blocks.py function get_down_block (line 42) | def get_down_block( function get_up_block (line 251) | def get_up_block( class AutoencoderTinyBlock (line 476) | class AutoencoderTinyBlock(nn.Module): method __init__ (line 492) | def __init__(self, in_channels: int, out_channels: int, act_fn: str): method forward (line 509) | def forward(self, x: torch.FloatTensor) -> torch.FloatTensor: class UNetMidBlock2D (line 513) | class UNetMidBlock2D(nn.Module): method __init__ (line 544) | def __init__( method forward (line 628) | def forward(self, hidden_states: torch.FloatTensor, temb: Optional[tor... class UNetMidBlock2DCrossAttn (line 638) | class UNetMidBlock2DCrossAttn(nn.Module): method __init__ (line 639) | def __init__( method forward (line 732) | def forward( class UNetMidBlock2DSimpleCrossAttn (line 784) | class UNetMidBlock2DSimpleCrossAttn(nn.Module): method __init__ (line 785) | def __init__( method forward (line 869) | def forward( class AttnDownBlock2D (line 908) | class AttnDownBlock2D(nn.Module): method __init__ (line 909) | def __init__( method forward (line 1000) | def forward( class CrossAttnDownBlock2D (line 1031) | class CrossAttnDownBlock2D(nn.Module): method __init__ (line 1032) | def __init__( method forward (line 1124) | def forward( class DownBlock2D (line 1193) | class DownBlock2D(nn.Module): method __init__ (line 1194) | def __init__( method forward (line 1245) | def forward( class DownEncoderBlock2D (line 1281) | class DownEncoderBlock2D(nn.Module): method __init__ (line 1282) | def __init__( method forward (line 1330) | def forward(self, hidden_states: torch.FloatTensor, scale: float = 1.0... class AttnDownEncoderBlock2D (line 1341) | class AttnDownEncoderBlock2D(nn.Module): method __init__ (line 1342) | def __init__( method forward (line 1413) | def forward(self, hidden_states: torch.FloatTensor, scale: float = 1.0... class AttnSkipDownBlock2D (line 1426) | class AttnSkipDownBlock2D(nn.Module): method __init__ (line 1427) | def __init__( method forward (line 1507) | def forward( class SkipDownBlock2D (line 1534) | class SkipDownBlock2D(nn.Module): method __init__ (line 1535) | def __init__( method forward (line 1594) | def forward( class ResnetDownsampleBlock2D (line 1619) | class ResnetDownsampleBlock2D(nn.Module): method __init__ (line 1620) | def __init__( method forward (line 1683) | def forward( class SimpleCrossAttnDownBlock2D (line 1719) | class SimpleCrossAttnDownBlock2D(nn.Module): method __init__ (line 1720) | def __init__( method forward (line 1814) | def forward( class KDownBlock2D (line 1879) | class KDownBlock2D(nn.Module): method __init__ (line 1880) | def __init__( method forward (line 1925) | def forward( class KCrossAttnDownBlock2D (line 1959) | class KCrossAttnDownBlock2D(nn.Module): method __init__ (line 1960) | def __init__( method forward (line 2024) | def forward( class AttnUpBlock2D (line 2086) | class AttnUpBlock2D(nn.Module): method __init__ (line 2087) | def __init__( method forward (line 2178) | def forward( class CrossAttnUpBlock2D (line 2206) | class CrossAttnUpBlock2D(nn.Module): method __init__ (line 2207) | def __init__( method forward (line 2298) | def forward( class UpBlock2D (line 2380) | class UpBlock2D(nn.Module): method __init__ (line 2381) | def __init__( method forward (line 2430) | def forward( class UpDecoderBlock2D (line 2490) | class UpDecoderBlock2D(nn.Module): method __init__ (line 2491) | def __init__( method forward (line 2537) | def forward( class AttnUpDecoderBlock2D (line 2550) | class AttnUpDecoderBlock2D(nn.Module): method __init__ (line 2551) | def __init__( method forward (line 2621) | def forward( class AttnSkipUpBlock2D (line 2636) | class AttnSkipUpBlock2D(nn.Module): method __init__ (line 2637) | def __init__( method forward (line 2730) | def forward( class SkipUpBlock2D (line 2766) | class SkipUpBlock2D(nn.Module): method __init__ (line 2767) | def __init__( method forward (line 2838) | def forward( class ResnetUpsampleBlock2D (line 2871) | class ResnetUpsampleBlock2D(nn.Module): method __init__ (line 2872) | def __init__( method forward (line 2940) | def forward( class SimpleCrossAttnUpBlock2D (line 2980) | class SimpleCrossAttnUpBlock2D(nn.Module): method __init__ (line 2981) | def __init__( method forward (line 3079) | def forward( class KUpBlock2D (line 3146) | class KUpBlock2D(nn.Module): method __init__ (line 3147) | def __init__( method forward (line 3196) | def forward( class KCrossAttnUpBlock2D (line 3235) | class KCrossAttnUpBlock2D(nn.Module): method __init__ (line 3236) | def __init__( method forward (line 3321) | def forward( class KAttentionBlock (line 3383) | class KAttentionBlock(nn.Module): method __init__ (line 3407) | def __init__( method _to_3d (line 3450) | def _to_3d(self, hidden_states: torch.FloatTensor, height: int, weight... method _to_4d (line 3453) | def _to_4d(self, hidden_states: torch.FloatTensor, height: int, weight... method forward (line 3456) | def forward( FILE: foleycrafter/models/auffusion_unet.py class UNet2DConditionOutput (line 64) | class UNet2DConditionOutput(BaseOutput): class UNet2DConditionModel (line 76) | class UNet2DConditionModel(ModelMixin, ConfigMixin, UNet2DConditionLoade... method __init__ (line 173) | def __init__( method load_attention (line 639) | def load_attention(self): method get_writer_feature (line 652) | def get_writer_feature(self): method clear_writer_feature (line 655) | def clear_writer_feature(self): method disable_feature_adapters (line 658) | def disable_feature_adapters(self): method set_reader_feature (line 661) | def set_reader_feature(self, features: list): method attn_processors (line 665) | def attn_processors(self) -> Dict[str, AttentionProcessor]: method set_attn_processor (line 688) | def set_attn_processor( method set_default_attn_processor (line 724) | def set_default_attn_processor(self): method set_attention_slice (line 739) | def set_attention_slice(self, slice_size): method _set_gradient_checkpointing (line 804) | def _set_gradient_checkpointing(self, module, value=False): method enable_freeu (line 808) | def enable_freeu(self, s1, s2, b1, b2): method disable_freeu (line 832) | def disable_freeu(self): method fuse_qkv_projections (line 840) | def fuse_qkv_projections(self): method unfuse_qkv_projections (line 863) | def unfuse_qkv_projections(self): method forward (line 876) | def forward( FILE: foleycrafter/models/onset/r2plus1d_18.py class r2plus1d18KeepTemp (line 9) | class r2plus1d18KeepTemp(nn.Module): method __init__ (line 10) | def __init__(self, pretrained=True): method forward (line 39) | def forward(self, x): FILE: foleycrafter/models/onset/resnet.py class Conv3DSimple (line 15) | class Conv3DSimple(nn.Conv3d): method __init__ (line 16) | def __init__(self, in_planes, out_planes, midplanes=None, stride=1, pa... method get_downsample_stride (line 27) | def get_downsample_stride(stride): class Conv2Plus1D (line 31) | class Conv2Plus1D(nn.Sequential): method __init__ (line 32) | def __init__(self, in_planes, out_planes, midplanes, stride=1, padding... method get_downsample_stride (line 55) | def get_downsample_stride(stride): class Conv3DNoTemporal (line 59) | class Conv3DNoTemporal(nn.Conv3d): method __init__ (line 60) | def __init__(self, in_planes, out_planes, midplanes=None, stride=1, pa... method get_downsample_stride (line 71) | def get_downsample_stride(stride): class BasicBlock (line 75) | class BasicBlock(nn.Module): method __init__ (line 78) | def __init__(self, inplanes, planes, conv_builder, stride=1, downsampl... method forward (line 90) | def forward(self, x): class Bottleneck (line 104) | class Bottleneck(nn.Module): method __init__ (line 107) | def __init__(self, inplanes, planes, conv_builder, stride=1, downsampl... method forward (line 129) | def forward(self, x): class BasicStem (line 145) | class BasicStem(nn.Sequential): method __init__ (line 148) | def __init__(self): class R2Plus1dStem (line 156) | class R2Plus1dStem(nn.Sequential): method __init__ (line 159) | def __init__(self): class VideoResNet (line 170) | class VideoResNet(nn.Module): method __init__ (line 171) | def __init__(self, block, conv_makers, layers, stem, num_classes=400, ... method forward (line 202) | def forward(self, x): method _make_layer (line 221) | def _make_layer(self, block, conv_builder, planes, blocks, stride=1): method _initialize_weights (line 239) | def _initialize_weights(self): function _video_resnet (line 253) | def _video_resnet(arch, pretrained=False, progress=True, **kwargs): function r3d_18 (line 262) | def r3d_18(pretrained=False, progress=True, **kwargs): function mc3_18 (line 284) | def mc3_18(pretrained=False, progress=True, **kwargs): function r2plus1d_18 (line 305) | def r2plus1d_18(pretrained=False, progress=True, **kwargs): FILE: foleycrafter/models/onset/torch_utils.py function load_model (line 14) | def load_model(cp_path, net, device=None, strict=True): function binary_acc (line 42) | def binary_acc(pred, target, threshold): function calc_acc (line 48) | def calc_acc(prob, labels, k): function get_dataloader (line 57) | def get_dataloader(args, pr, split="train", shuffle=False, drop_last=Fal... function make_optimizer (line 81) | def make_optimizer(model, args): function adjust_learning_rate (line 105) | def adjust_learning_rate(optimizer, epoch, args): FILE: foleycrafter/models/onset/video_onset_net.py class VideoOnsetNet (line 9) | class VideoOnsetNet(nn.Module): method __init__ (line 11) | def __init__(self, pretrained): method forward (line 16) | def forward(self, inputs, loss=False, evaluate=False): FILE: foleycrafter/models/time_detector/model.py class TimeDetector (line 6) | class TimeDetector(nn.Module): method __init__ (line 7) | def __init__(self, video_length=150, audio_length=1024): method forward (line 13) | def forward(self, inputs): FILE: foleycrafter/models/time_detector/resnet.py class Conv3DSimple (line 14) | class Conv3DSimple(nn.Conv3d): method __init__ (line 15) | def __init__(self, in_planes, out_planes, midplanes=None, stride=1, pa... method get_downsample_stride (line 26) | def get_downsample_stride(stride): class Conv2Plus1D (line 30) | class Conv2Plus1D(nn.Sequential): method __init__ (line 31) | def __init__(self, in_planes, out_planes, midplanes, stride=1, padding... method get_downsample_stride (line 54) | def get_downsample_stride(stride): class Conv3DNoTemporal (line 58) | class Conv3DNoTemporal(nn.Conv3d): method __init__ (line 59) | def __init__(self, in_planes, out_planes, midplanes=None, stride=1, pa... method get_downsample_stride (line 70) | def get_downsample_stride(stride): class BasicBlock (line 74) | class BasicBlock(nn.Module): method __init__ (line 77) | def __init__(self, inplanes, planes, conv_builder, stride=1, downsampl... method forward (line 89) | def forward(self, x): class Bottleneck (line 103) | class Bottleneck(nn.Module): method __init__ (line 106) | def __init__(self, inplanes, planes, conv_builder, stride=1, downsampl... method forward (line 128) | def forward(self, x): class BasicStem (line 144) | class BasicStem(nn.Sequential): method __init__ (line 147) | def __init__(self): class R2Plus1dStem (line 155) | class R2Plus1dStem(nn.Sequential): method __init__ (line 158) | def __init__(self): class VideoResNet (line 169) | class VideoResNet(nn.Module): method __init__ (line 170) | def __init__(self, block, conv_makers, layers, stem, num_classes=400, ... method forward (line 201) | def forward(self, x): method _make_layer (line 220) | def _make_layer(self, block, conv_builder, planes, blocks, stride=1): method _initialize_weights (line 238) | def _initialize_weights(self): function _video_resnet (line 252) | def _video_resnet(arch, pretrained=False, progress=True, **kwargs): function r3d_18 (line 261) | def r3d_18(pretrained=False, progress=True, **kwargs): function mc3_18 (line 283) | def mc3_18(pretrained=False, progress=True, **kwargs): function r2plus1d_18 (line 304) | def r2plus1d_18(pretrained=False, progress=True, **kwargs): FILE: foleycrafter/pipelines/auffusion_pipeline.py function json_dump (line 66) | def json_dump(data_json, json_save_path): function json_load (line 72) | def json_load(json_path): function import_model_class_from_model_name_or_path (line 79) | def import_model_class_from_model_name_or_path(pretrained_model_name_or_... class ConditionAdapter (line 99) | class ConditionAdapter(nn.Module): method __init__ (line 100) | def __init__(self, config): method forward (line 107) | def forward(self, x): method from_pretrained (line 113) | def from_pretrained(cls, pretrained_model_name_or_path): method save_pretrained (line 122) | def save_pretrained(self, pretrained_model_name_or_path): function rescale_noise_cfg (line 131) | def rescale_noise_cfg(noise_cfg, noise_pred_text, guidance_rescale=0.0): class AttrDict (line 149) | class AttrDict(dict): method __init__ (line 150) | def __init__(self, *args, **kwargs): function get_config (line 155) | def get_config(config_path): function init_weights (line 161) | def init_weights(m, mean=0.0, std=0.01): function apply_weight_norm (line 167) | def apply_weight_norm(m): function get_padding (line 173) | def get_padding(kernel_size, dilation=1): class ResBlock1 (line 177) | class ResBlock1(torch.nn.Module): method __init__ (line 178) | def __init__(self, h, channels, kernel_size=3, dilation=(1, 3, 5)): method forward (line 232) | def forward(self, x): method remove_weight_norm (line 241) | def remove_weight_norm(self): class ResBlock2 (line 248) | class ResBlock2(torch.nn.Module): method __init__ (line 249) | def __init__(self, h, channels, kernel_size=3, dilation=(1, 3)): method forward (line 278) | def forward(self, x): method remove_weight_norm (line 285) | def remove_weight_norm(self): class Generator (line 290) | class Generator(torch.nn.Module): method __init__ (line 291) | def __init__(self, h): method device (line 347) | def device(self) -> torch.device: method dtype (line 351) | def dtype(self): method forward (line 354) | def forward(self, x): method remove_weight_norm (line 372) | def remove_weight_norm(self): method from_pretrained (line 382) | def from_pretrained(cls, pretrained_model_name_or_path, subfolder=None): method inference (line 398) | def inference(self, mels, lengths=None): function normalize_spectrogram (line 411) | def normalize_spectrogram( function denormalize_spectrogram (line 432) | def denormalize_spectrogram( function pt_to_numpy (line 457) | def pt_to_numpy(images: torch.FloatTensor) -> np.ndarray: function numpy_to_pil (line 466) | def numpy_to_pil(images: np.ndarray) -> PIL.Image.Image: function image_add_color (line 482) | def image_add_color(spec_img): class PipelineOutput (line 492) | class PipelineOutput(BaseOutput): class AuffusionPipeline (line 506) | class AuffusionPipeline(DiffusionPipeline): method __init__ (line 551) | def __init__( method from_pretrained (line 588) | def from_pretrained( method to (line 642) | def to(self, device, dtype=None): method enable_vae_slicing (line 656) | def enable_vae_slicing(self): method disable_vae_slicing (line 665) | def disable_vae_slicing(self): method enable_vae_tiling (line 672) | def enable_vae_tiling(self): method disable_vae_tiling (line 681) | def disable_vae_tiling(self): method enable_sequential_cpu_offload (line 688) | def enable_sequential_cpu_offload(self, gpu_id=0): method enable_model_cpu_offload (line 713) | def enable_model_cpu_offload(self, gpu_id=0): method _execution_device (line 742) | def _execution_device(self): method _encode_prompt (line 759) | def _encode_prompt( method run_safety_checker (line 862) | def run_safety_checker(self, image, device, dtype): method decode_latents (line 876) | def decode_latents(self, latents): method prepare_extra_step_kwargs (line 889) | def prepare_extra_step_kwargs(self, generator, eta): method check_inputs (line 906) | def check_inputs( method prepare_latents (line 953) | def prepare_latents(self, batch_size, num_channels_latents, height, wi... method __call__ (line 971) | def __call__( function retrieve_timesteps (line 1120) | def retrieve_timesteps( class AuffusionNoAdapterPipeline (line 1164) | class AuffusionNoAdapterPipeline( method __init__ (line 1205) | def __init__( method enable_vae_slicing (line 1297) | def enable_vae_slicing(self): method disable_vae_slicing (line 1304) | def disable_vae_slicing(self): method enable_vae_tiling (line 1311) | def enable_vae_tiling(self): method disable_vae_tiling (line 1319) | def disable_vae_tiling(self): method _encode_prompt (line 1326) | def _encode_prompt( method encode_prompt (line 1358) | def encode_prompt( method prepare_ip_adapter_image_embeds (line 1529) | def prepare_ip_adapter_image_embeds( method encode_image (line 1580) | def encode_image(self, image, device, num_images_per_prompt, output_hi... method run_safety_checker (line 1604) | def run_safety_checker(self, image, device, dtype): method decode_latents (line 1618) | def decode_latents(self, latents): method prepare_extra_step_kwargs (line 1629) | def prepare_extra_step_kwargs(self, generator, eta): method check_inputs (line 1646) | def check_inputs( method prepare_latents (line 1698) | def prepare_latents(self, batch_size, num_channels_latents, height, wi... method enable_freeu (line 1715) | def enable_freeu(self, s1: float, s2: float, b1: float, b2: float): method disable_freeu (line 1737) | def disable_freeu(self): method fuse_qkv_projections (line 1742) | def fuse_qkv_projections(self, unet: bool = True, vae: bool = True): method unfuse_qkv_projections (line 1774) | def unfuse_qkv_projections(self, unet: bool = True, vae: bool = True): method get_guidance_scale_embedding (line 1803) | def get_guidance_scale_embedding(self, w, embedding_dim=512, dtype=tor... method guidance_scale (line 1832) | def guidance_scale(self): method guidance_rescale (line 1836) | def guidance_rescale(self): method clip_skip (line 1840) | def clip_skip(self): method do_classifier_free_guidance (line 1847) | def do_classifier_free_guidance(self): method cross_attention_kwargs (line 1851) | def cross_attention_kwargs(self): method num_timesteps (line 1855) | def num_timesteps(self): method interrupt (line 1859) | def interrupt(self): method __call__ (line 1863) | def __call__( FILE: foleycrafter/pipelines/pipeline_controlnet.py function retrieve_timesteps (line 97) | def retrieve_timesteps( class StableDiffusionControlNetPipeline (line 141) | class StableDiffusionControlNetPipeline( method __init__ (line 186) | def __init__( method enable_vae_slicing (line 239) | def enable_vae_slicing(self): method disable_vae_slicing (line 247) | def disable_vae_slicing(self): method enable_vae_tiling (line 255) | def enable_vae_tiling(self): method disable_vae_tiling (line 264) | def disable_vae_tiling(self): method _encode_prompt (line 272) | def _encode_prompt( method encode_prompt (line 305) | def encode_prompt( method prepare_ip_adapter_image_embeds (line 486) | def prepare_ip_adapter_image_embeds( method encode_image (line 538) | def encode_image(self, image, device, num_images_per_prompt, output_hi... method run_safety_checker (line 563) | def run_safety_checker(self, image, device, dtype): method decode_latents (line 578) | def decode_latents(self, latents): method prepare_extra_step_kwargs (line 590) | def prepare_extra_step_kwargs(self, generator, eta): method check_inputs (line 607) | def check_inputs( method check_image (line 753) | def check_image(self, image, prompt, prompt_embeds): method prepare_image (line 790) | def prepare_image( method prepare_latents (line 821) | def prepare_latents(self, batch_size, num_channels_latents, height, wi... method enable_freeu (line 839) | def enable_freeu(self, s1: float, s2: float, b1: float, b2: float): method disable_freeu (line 862) | def disable_freeu(self): method get_guidance_scale_embedding (line 867) | def get_guidance_scale_embedding(self, w, embedding_dim=512, dtype=tor... method guidance_scale (line 896) | def guidance_scale(self): method clip_skip (line 900) | def clip_skip(self): method do_classifier_free_guidance (line 907) | def do_classifier_free_guidance(self): method cross_attention_kwargs (line 911) | def cross_attention_kwargs(self): method num_timesteps (line 915) | def num_timesteps(self): method __call__ (line 920) | def __call__( FILE: foleycrafter/utils/converter.py function load_wav (line 23) | def load_wav(full_path): function dynamic_range_compression (line 28) | def dynamic_range_compression(x, C=1, clip_val=1e-5): function dynamic_range_decompression (line 32) | def dynamic_range_decompression(x, C=1): function dynamic_range_compression_torch (line 36) | def dynamic_range_compression_torch(x, C=1, clip_val=1e-5): function dynamic_range_decompression_torch (line 40) | def dynamic_range_decompression_torch(x, C=1): function spectral_normalize_torch (line 44) | def spectral_normalize_torch(magnitudes): function spectral_de_normalize_torch (line 49) | def spectral_de_normalize_torch(magnitudes): function mel_spectrogram (line 58) | def mel_spectrogram(y, n_fft, num_mels, sampling_rate, hop_size, win_siz... function spectrogram (line 97) | def spectrogram(y, n_fft, num_mels, sampling_rate, hop_size, win_size, f... function normalize_spectrogram (line 130) | def normalize_spectrogram( function denormalize_spectrogram (line 161) | def denormalize_spectrogram( function get_mel_spectrogram_from_audio (line 195) | def get_mel_spectrogram_from_audio(audio, device="cpu"): class AttrDict (line 222) | class AttrDict(dict): method __init__ (line 223) | def __init__(self, *args, **kwargs): function get_config (line 228) | def get_config(config_path): function init_weights (line 234) | def init_weights(m, mean=0.0, std=0.01): function apply_weight_norm (line 240) | def apply_weight_norm(m): function get_padding (line 246) | def get_padding(kernel_size, dilation=1): class ResBlock1 (line 250) | class ResBlock1(torch.nn.Module): method __init__ (line 251) | def __init__(self, h, channels, kernel_size=3, dilation=(1, 3, 5)): method forward (line 305) | def forward(self, x): method remove_weight_norm (line 314) | def remove_weight_norm(self): class ResBlock2 (line 321) | class ResBlock2(torch.nn.Module): method __init__ (line 322) | def __init__(self, h, channels, kernel_size=3, dilation=(1, 3)): method forward (line 351) | def forward(self, x): method remove_weight_norm (line 358) | def remove_weight_norm(self): class Generator (line 363) | class Generator(torch.nn.Module): method __init__ (line 364) | def __init__(self, h): method forward (line 416) | def forward(self, x): method remove_weight_norm (line 434) | def remove_weight_norm(self): method from_pretrained (line 443) | def from_pretrained(cls, pretrained_model_name_or_path, subfolder=None): method inference (line 459) | def inference(self, mels, lengths=None): function normalize (line 472) | def normalize(images): function pad_spec (line 482) | def pad_spec(spec, spec_length, pad_value=0, random_crop=True): # spec:... FILE: foleycrafter/utils/spec_to_mel.py class STFT (line 14) | class STFT(torch.nn.Module): method __init__ (line 17) | def __init__(self, filter_length, hop_length, win_length, window="hann"): method transform (line 47) | def transform(self, input_data): method inverse (line 78) | def inverse(self, magnitude, phase): method forward (line 111) | def forward(self, input_data): function window_sumsquare (line 117) | def window_sumsquare( function griffin_lim (line 176) | def griffin_lim(magnitudes, stft_fn, n_iters=30): function dynamic_range_compression (line 195) | def dynamic_range_compression(x, normalize_fun=torch.log, C=1, clip_val=... function dynamic_range_decompression (line 204) | def dynamic_range_decompression(x, C=1): class TacotronSTFT (line 213) | class TacotronSTFT(torch.nn.Module): method __init__ (line 214) | def __init__( method spectral_normalize (line 232) | def spectral_normalize(self, magnitudes, normalize_fun): method spectral_de_normalize (line 236) | def spectral_de_normalize(self, magnitudes): method mel_spectrogram (line 240) | def mel_spectrogram(self, y, normalize_fun=torch.log): function pad_wav (line 264) | def pad_wav(waveform, segment_length): function normalize_wav (line 277) | def normalize_wav(waveform): function _pad_spec (line 283) | def _pad_spec(fbank, target_length=1024): function get_mel_from_wav (line 299) | def get_mel_from_wav(audio, _stft): function read_wav_file_io (line 309) | def read_wav_file_io(bytes): function load_audio (line 323) | def load_audio(bytes, sample_rate=16000): function read_wav_file (line 329) | def read_wav_file(filename): function norm_wav_tensor (line 343) | def norm_wav_tensor(waveform: torch.FloatTensor): function wav_to_fbank (line 352) | def wav_to_fbank(filename, target_length=1024, fn_STFT=None): function wav_tensor_to_fbank (line 380) | def wav_tensor_to_fbank(waveform, target_length=512, fn_STFT=None): FILE: foleycrafter/utils/util.py function zero_rank_print (line 35) | def zero_rank_print(s): function build_foleycrafter (line 40) | def build_foleycrafter( function save_videos_grid (line 66) | def save_videos_grid(videos: torch.Tensor, path: str, rescale=False, n_r... function save_videos_from_pil_list (line 82) | def save_videos_from_pil_list(videos: list, path: str, fps=7): function seed_everything (line 89) | def seed_everything(seed: int) -> None: function get_video_frames (line 102) | def get_video_frames(video: np.ndarray, num_frames: int = 200): function random_audio_video_clip (line 109) | def random_audio_video_clip( function get_full_indices (line 142) | def get_full_indices(reader: Union[decord.VideoReader, decord.AudioReade... function get_frames (line 149) | def get_frames(video_path: str, onset_list, frame_nums=1024): function get_frames_in_video (line 163) | def get_frames_in_video(video_path: str, onset_list, frame_nums=1024, au... function save_multimodal (line 183) | def save_multimodal(video, audio, output_path, audio_fps: int = 16000, v... function save_multimodal_by_frame (line 203) | def save_multimodal_by_frame(video, audio, output_path, audio_fps: int =... function sanity_check (line 221) | def sanity_check(data: dict, save_path: str = "sanity_check", batch_size... function video_tensor_to_np (line 242) | def video_tensor_to_np(video: torch.Tensor, rescale: bool = True, scale:... function composite_audio_video (line 255) | def composite_audio_video(video: str, audio: str, path: str, video_fps: ... function append_dims (line 265) | def append_dims(x, target_dims): function resize_with_antialiasing (line 273) | def resize_with_antialiasing(input, size, interpolation="bicubic", align... function _gaussian_blur2d (line 302) | def _gaussian_blur2d(input, kernel_size, sigma): function _filter2d (line 318) | def _filter2d(input, kernel): function _gaussian (line 341) | def _gaussian(window_size: int, sigma): function _compute_padding (line 357) | def _compute_padding(kernel_size): function print_gpu_memory_usage (line 380) | def print_gpu_memory_usage(info: str, cuda_id: int = 0): class SpectrogramParams (line 392) | class SpectrogramParams: class ExifTags (line 427) | class ExifTags(Enum): method n_fft (line 446) | def n_fft(self) -> int: method win_length (line 453) | def win_length(self) -> int: method hop_length (line 460) | def hop_length(self) -> int: method to_exif (line 466) | def to_exif(self) -> T.Dict[int, T.Any]: class SpectrogramImageConverter (line 483) | class SpectrogramImageConverter: method __init__ (line 491) | def __init__(self, params: SpectrogramParams, device: str = "cuda"): method spectrogram_image_from_audio (line 496) | def spectrogram_image_from_audio( method audio_from_spectrogram_image (line 538) | def audio_from_spectrogram_image( function image_from_spectrogram (line 567) | def image_from_spectrogram(spectrogram: np.ndarray, power: float = 0.25)... function spectrogram_from_image (line 613) | def spectrogram_from_image( class SpectrogramConverter (line 667) | class SpectrogramConverter: method __init__ (line 689) | def __init__(self, params: SpectrogramParams, device: str = "cuda"): method spectrogram_from_audio (line 756) | def spectrogram_from_audio( method audio_from_spectrogram (line 782) | def audio_from_spectrogram( method mel_amplitudes_from_waveform (line 820) | def mel_amplitudes_from_waveform( method waveform_from_mel_amplitudes (line 842) | def waveform_from_mel_amplitudes( function check_device (line 862) | def check_device(device: str, backup: str = "cpu") -> str: function audio_from_waveform (line 876) | def audio_from_waveform(samples: np.ndarray, sample_rate: int, normalize... function apply_filters_func (line 900) | def apply_filters_func(segment: pydub.AudioSegment, compression: bool = ... function shave_segments (line 936) | def shave_segments(path, n_shave_prefix_segments=1): function renew_resnet_paths (line 946) | def renew_resnet_paths(old_list, n_shave_prefix_segments=0): function renew_vae_resnet_paths (line 968) | def renew_vae_resnet_paths(old_list, n_shave_prefix_segments=0): function renew_attention_paths (line 984) | def renew_attention_paths(old_list, n_shave_prefix_segments=0): function renew_vae_attention_paths (line 1005) | def renew_vae_attention_paths(old_list, n_shave_prefix_segments=0): function assign_to_checkpoint (line 1034) | def assign_to_checkpoint( function conv_attn_to_linear (line 1089) | def conv_attn_to_linear(checkpoint): function create_unet_diffusers_config (line 1101) | def create_unet_diffusers_config(original_config, image_size: int, contr... function create_vae_diffusers_config (line 1170) | def create_vae_diffusers_config(original_config, image_size: int): function create_diffusers_schedular (line 1194) | def create_diffusers_schedular(original_config): function convert_ldm_unet_checkpoint (line 1204) | def convert_ldm_unet_checkpoint(checkpoint, config, path=None, extract_e... function convert_ldm_vae_checkpoint (line 1435) | def convert_ldm_vae_checkpoint(checkpoint, config, only_decoder=False, o... function convert_ldm_clip_checkpoint (line 1550) | def convert_ldm_clip_checkpoint(checkpoint): function convert_lora_model_level (line 1561) | def convert_lora_model_level( function denormalize_spectrogram (line 1643) | def denormalize_spectrogram( class ToTensor1D (line 1677) | class ToTensor1D(torchvision.transforms.ToTensor): method __call__ (line 1678) | def __call__(self, tensor: np.ndarray): function scale (line 1684) | def scale(old_value, old_min, old_max, new_min, new_max): function read_frames_with_moviepy (line 1692) | def read_frames_with_moviepy(video_path, max_frame_nums=None): function read_frames_with_moviepy_resample (line 1703) | def read_frames_with_moviepy_resample(video_path, save_path): FILE: inference.py function args_parse (line 28) | def args_parse(): function build_models (line 49) | def build_models(config): function run_inference (line 97) | def run_inference(config, pipe, vocoder, time_detector):