MCPcopy Create free account

hub / github.com/ShihaoZhaoZSH/Uni-ControlNet / functions

Functions2,265 in github.com/ShihaoZhaoZSH/Uni-ControlNet

↓ 255 callersMethodsize
(self)
annotator/uniformer/mmcv/video/io.py:27
↓ 78 callersFunctionexpand_dims
Expand the tensor `v` to the dim `dims`. Args: `v`: a PyTorch tensor with shape [N]. `dim`: a `int`. Returns: a P
ldm/models/diffusion/dpm_solver/dpm_solver.py:1145
↓ 73 callersMethodget
(self, key, default=None)
annotator/uniformer/mmcv/video/io.py:37
↓ 66 callersMethodupdate
(self, vars, count=1)
annotator/uniformer/mmcv/runner/log_buffer.py:24
↓ 48 callersMethoddim
(self)
annotator/uniformer/mmcv/parallel/data_container.py:88
↓ 43 callersMethodregister_buffer
(self, name, attr)
ldm/models/diffusion/ddim.py:17
↓ 42 callersMethodload
Load model from file. Args: path (str): file path
annotator/midas/midas/base_model.py:5
↓ 38 callersFunctionbuild_norm_layer
Build normalization layer. Args: cfg (dict): The norm layer config, which should contain: - type (str): Layer type.
annotator/uniformer/mmcv/cnn/bricks/norm.py:72
↓ 34 callersFunctionconstant_init
(module, val, bias=0)
annotator/uniformer/mmcv/cnn/utils/weight_init.py:48
↓ 33 callersFunctionbuild_conv_layer
Build convolution layer. Args: cfg (None or dict): The conv layer config, which should contain: - type (str): Layer type.
annotator/uniformer/mmcv/cnn/bricks/conv.py:12
↓ 32 callersFunctiondigit_version
Convert a version string into a tuple of integers. This method is usually used for comparing two versions. For pre-release versions: alpha <
annotator/uniformer/mmcv/utils/version_utils.py:9
↓ 31 callersFunctionconv_nd
Create a 1D, 2D, or 3D convolution module.
ldm/modules/diffusionmodules/util.py:221
↓ 26 callersMethodlog
(self, runner)
annotator/uniformer/mmcv/runner/hooks/logger/base.py:35
↓ 26 callersMethodregister_module
Register a module. A record will be added to `self._module_dict`, whose key is the class name or the specified name, and value is the
annotator/uniformer/mmcv/utils/registry.py:260
↓ 26 callersFunctionresize
(input, size=None, scale_factor=None, mode='nearest', align_corner
annotator/uniformer/mmseg/ops/wrappers.py:7
↓ 25 callersFunctionextract_into_tensor
(a, t, x_shape)
ldm/modules/diffusionmodules/util.py:96
↓ 25 callersMethodload_state_dict
Loads the loss_scaler state dict. Args: state_dict (dict): scaler state.
annotator/uniformer/mmcv/runner/fp16_utils.py:395
↓ 25 callersMethodregister_buffer
(self, name, attr)
models/ddim_hacked.py:17
↓ 23 callersMethodstack
(self)
annotator/uniformer/mmcv/parallel/data_container.py:72
↓ 21 callersMethod_transform_inputs
Transform inputs for decoder. Args: inputs (list[Tensor]): List of multi-level img features. Returns: Tensor
annotator/uniformer/mmseg/models/decode_heads/decode_head.py:137
↓ 21 callersFunctionexists
(x)
ldm/util.py:47
↓ 20 callersMethodcls_seg
Classify each pixel with fc.
annotator/uniformer/mmseg/models/decode_heads/point_head.py:108
↓ 20 callersMethoddecode_first_stage
(self, z, predict_cids=False, force_not_quantize=False)
ldm/models/diffusion/ddpm.py:820
↓ 20 callersMethodexists
Check whether a file path exists. Args: filepath (str or Path): Path to be checked whether exists. Returns:
annotator/uniformer/mmcv/fileio/file_client.py:1043
↓ 19 callersMethodmarginal_lambda
Compute lambda_t = log(alpha_t) - log(sigma_t) of a given continuous-time label t in [0, T].
ldm/models/diffusion/dpm_solver/dpm_solver.py:132
↓ 19 callersMethodstate_dict
Returns the state of the scaler as a :class:`dict`.
annotator/uniformer/mmcv/runner/fp16_utils.py:385
↓ 18 callersMethodcall_hook
Call all hooks. Args: fn_name (str): The function name in each hook to be called, such as "before_train_epoch".
annotator/uniformer/mmcv/runner/base_runner.py:299
↓ 18 callersMethodmarginal_std
Compute sigma_t of a given continuous-time label t in [0, T].
ldm/models/diffusion/dpm_solver/dpm_solver.py:126
↓ 17 callersFunctionget_dist_info
()
annotator/uniformer/mmcv/runner/dist_utils.py:78
↓ 17 callersMethodread
Read the next frame. If the next frame have been decoded before and in the cache, then return it directly, otherwise decode, cache an
annotator/uniformer/mmcv/video/io.py:134
↓ 16 callersFunctionbuild_from_cfg
Build a module from config dict. Args: cfg (dict): Config dict. It should at least contain the key "type". registry (:obj:`Regist
annotator/uniformer/mmcv/utils/registry.py:9
↓ 16 callersFunctioninstantiate_from_config
(config)
ldm/util.py:72
↓ 16 callersFunctionkaiming_init
(module, a=0, mode='fan_out', nonlinearity='relu',
annotator/uniformer/mmcv/cnn/utils/weight_init.py:92
↓ 16 callersMethodmarginal_log_mean_coeff
Compute log(alpha_t) of a given continuous-time label t in [0, T].
ldm/models/diffusion/dpm_solver/dpm_solver.py:106
↓ 15 callersFunctionHWC3
(x)
annotator/util.py:9
↓ 15 callersMethodmodel_fn
Convert the model to the noise prediction model or the data prediction model.
ldm/models/diffusion/dpm_solver/dpm_solver.py:367
↓ 15 callersFunctionprint_log
Print a log message. Args: msg (str): The message to be logged. logger (logging.Logger | str | None): The logger to be used.
annotator/uniformer/mmcv/utils/logging.py:85
↓ 15 callersMethodq_sample
(self, x_start, t, noise=None)
ldm/models/diffusion/ddpm.py:356
↓ 15 callersMethodremove
Remove a file. Args: filepath (str, Path): Path to be removed.
annotator/uniformer/mmcv/fileio/file_client.py:1035
↓ 14 callersMethod__init__
(self, *, ch, out_ch, ch_mult=(1,2,4,8), num_res_blocks, attn_resolutions, dropout=0.0, resam
ldm/modules/diffusionmodules/model.py:301
↓ 14 callersMethoddecode
(self, x_latent, cond, t_start, unconditional_guidance_scale=1.0, unconditional_conditioning=None,
models/ddim_hacked.py:299
↓ 13 callersMethodregister_buffer
(self, name, attr)
ldm/models/diffusion/plms.py:19
↓ 12 callersFunctionload_checkpoint
Load checkpoint from a file or URI. Args: model (Module): Module to load checkpoint. filename (str): Accept local filepath, URL,
annotator/uniformer/mmcv/runner/checkpoint.py:503
↓ 12 callersMethodnorm
(self)
annotator/uniformer/mmcv/cnn/bricks/conv_module.py:169
↓ 11 callersMethodget_input
(self, batch, k)
ldm/models/diffusion/ddpm.py:419
↓ 11 callersFunctionis_str
Whether the input is an string instance. Note: This method is deprecated since python 2 is no longer supported.
annotator/uniformer/mmcv/utils/misc.py:31
↓ 11 callersFunctionnormal_init
(module, mean=0, std=1, bias=0)
annotator/uniformer/mmcv/cnn/utils/weight_init.py:66
↓ 10 callersMethod__init__
(self, by_epoch=True, warmup=None, warmup_iters=0,
annotator/uniformer/mmcv/runner/hooks/lr_updater.py:25
↓ 10 callersMethod_format_path
Convert a ``filepath`` to standard format of petrel oss. If the ``filepath`` is concatenated by ``os.path.join``, in a Windows enviro
annotator/uniformer/mmcv/fileio/file_client.py:134
↓ 10 callersMethod_map_path
Map ``filepath`` to a string path whose prefix will be replaced by :attr:`self.path_mapping`. Args: filepath (str): Path
annotator/uniformer/mmcv/fileio/file_client.py:121
↓ 10 callersFunctionget_activation
(name)
annotator/midas/midas/vit.py:159
↓ 10 callersMethodget_iter
Get the current training iteration step.
annotator/uniformer/mmcv/runner/hooks/logger/base.py:84
↓ 10 callersMethodisfile
Check whether a file path is a file. Args: filepath (str or Path): Path to be checked whether it is a file. Returns:
annotator/uniformer/mmcv/fileio/file_client.py:1067
↓ 10 callersMethodregister_hook
Register a hook into the hook list. The hook will be inserted into a priority queue, with the specified priority (See :class:`Priorit
annotator/uniformer/mmcv/runner/base_runner.py:255
↓ 9 callersFunctionNormalize
(in_channels, num_groups=32)
ldm/modules/diffusionmodules/model.py:46
↓ 9 callersMethodapply_model
(self, x_noisy, t, cond, return_ids=False)
ldm/models/diffusion/ddpm.py:850
↓ 9 callersFunctioncast_tensor_type
Recursively convert Tensor in inputs from src_type to dst_type. Args: inputs: Inputs that to be casted. src_type (torch.dtype): S
annotator/uniformer/mmcv/runner/fp16_utils.py:24
↓ 9 callersMethoddump
(self, file=None)
annotator/uniformer/mmcv/utils/config.py:534
↓ 9 callersMethodget_learned_conditioning
(self, c)
ldm/models/diffusion/ddpm.py:664
↓ 9 callersMethodinfer_client
Infer a suitable file client based on the URI and arguments. Args: file_client_args (dict, optional): Arguments to instantiate a
annotator/uniformer/mmcv/fileio/file_client.py:858
↓ 9 callersFunctionis_module_wrapper
Check if a module is a module wrapper. The following 3 modules in MMCV (and their subclasses) are regarded as module wrappers: DataParallel,
annotator/uniformer/mmcv/parallel/utils.py:5
↓ 9 callersFunctionnonlinearity
(x)
ldm/modules/diffusionmodules/model.py:41
↓ 9 callersMethodnorm1
nn.Module: the normalization layer named "norm1"
annotator/uniformer/mmseg/models/backbones/hrnet.py:362
↓ 9 callersMethodnorm2
nn.Module: the normalization layer named "norm2"
annotator/uniformer/mmseg/models/backbones/hrnet.py:367
↓ 9 callersMethodsample_log
(self, cond, batch_size, ddim, ddim_steps, **kwargs)
ldm/models/diffusion/ddpm.py:1110
↓ 9 callersMethodupdate
(self, num_tasks=1)
annotator/uniformer/mmcv/utils/progressbar.py:35
↓ 9 callersFunctionzero_module
Zero out the parameters of a module and return it.
ldm/modules/diffusionmodules/util.py:177
↓ 8 callersMethod__init__
(self, channels, use_conv, dims=2, out_channels=None, padding=1)
ldm/modules/diffusionmodules/openaimodel.py:99
↓ 8 callersFunctionadd_prefix
Add prefix for dict. Args: inputs (dict): The input dict with str keys. prefix (str): The prefix to add. Returns: d
annotator/uniformer/mmseg/core/utils/misc.py:1
↓ 8 callersMethodconvert
Multiple with alpha and add beat with clip.
annotator/uniformer/mmseg/datasets/pipelines/transforms.py:804
↓ 8 callersMethodevery_n_iters
(self, runner, n)
annotator/uniformer/mmcv/runner/hooks/hook.py:61
↓ 8 callersMethodfromfile
(filename, use_predefined_variables=True, import_custom_modules=True)
annotator/uniformer/mmcv/utils/config.py:328
↓ 8 callersFunctionget_root_logger
Get the root logger. The logger will be initialized if it has not been initialized. By default a StreamHandler will be added. If `log_file` i
annotator/uniformer/mmseg/utils/logger.py:6
↓ 8 callersFunctionupdate_init_info
Update the `_params_init_info` in the module if the value of parameters are changed. Args: module (obj:`nn.Module`): The module of Py
annotator/uniformer/mmcv/cnn/utils/weight_init.py:16
↓ 7 callersMethod__init__
(self, in_features, hidden_features=None, out_features=None, act_layer=nn.GELU, drop=0.)
annotator/uniformer/mmseg/models/backbones/uniformer.py:25
↓ 7 callersMethod__init__
(self, *, bias=0, bias_prob=None, layer=None)
annotator/uniformer/mmcv/cnn/utils/weight_init.py:134
↓ 7 callersMethod__init__
(self, unet_config, timesteps=1000, beta_schedule="linear",
ldm/models/diffusion/ddpm.py:48
↓ 7 callersMethod__setattr__
(self, name, value)
annotator/uniformer/mmcv/utils/config.py:512
↓ 7 callersMethodbuild
(self, *args, **kwargs)
annotator/uniformer/mmcv/utils/registry.py:211
↓ 7 callersMethodclear
(self)
annotator/uniformer/mmcv/runner/log_buffer.py:15
↓ 7 callersMethodencode
(self, x0, c, t_enc, use_original_steps=False, return_intermediates=None, unconditional_guidanc
models/ddim_hacked.py:236
↓ 7 callersMethodisdir
Check whether a file path is a directory. Args: filepath (str or Path): Path to be checked whether it is a direct
annotator/uniformer/mmcv/fileio/file_client.py:1054
↓ 7 callersMethodjoin_path
Concatenate all file paths. Join one or more filepath components intelligently. The return value is the concatenation of filepath and
annotator/uniformer/mmcv/fileio/file_client.py:1079
↓ 7 callersFunctionlog_txt_as_img
(wh, xc, size=10)
ldm/util.py:11
↓ 7 callersFunctionmake_attn
(in_channels, attn_type="vanilla", attn_kwargs=None)
ldm/modules/diffusionmodules/model.py:280
↓ 7 callersFunctionobsolete_torch_version
(torch_version, version_threshold)
annotator/uniformer/mmcv/cnn/bricks/wrappers.py:24
↓ 7 callersMethodsample
(self)
ldm/modules/distributions/distributions.py:17
↓ 7 callersMethodstep
Performs a single optimization step. Args: closure (callable, optional): A closure that reevaluates the model and
ldm/util.py:119
↓ 7 callersFunctionxavier_init
(module, gain=1, bias=0, distribution='normal')
annotator/uniformer/mmcv/cnn/utils/weight_init.py:55
↓ 6 callersMethod__init__
(self, in_c1, in_c2, out_c1, out_c2, upscale = True)
annotator/mlsd/models/mbv2_mlsd_tiny.py:10
↓ 6 callersMethod__init__
(self, in_c1, in_c2, out_c1, out_c2, upscale = True)
annotator/mlsd/models/mbv2_mlsd_large.py:10
↓ 6 callersMethod__init__
(self, dim_in, dim_out)
ldm/modules/attention.py:50
↓ 6 callersFunction_get_bases_name
(m)
annotator/uniformer/mmcv/cnn/utils/weight_init.py:128
↓ 6 callersMethod_get_denoise_row_from_list
(self, samples, desc='', force_no_decoder_quantization=False)
ldm/models/diffusion/ddpm.py:643
↓ 6 callersFunctionadd_JPEG_noise
(img)
ldm/modules/image_degradation/bsrgan.py:418
↓ 6 callersFunctionadd_blur
(img, sf=4)
ldm/modules/image_degradation/bsrgan.py:325
↓ 6 callersMethodbackward
(ctx, a=None)
annotator/uniformer/mmcv/ops/knn.py:73
↓ 6 callersMethodclip_grads
(self, params)
annotator/uniformer/mmcv/runner/hooks/optimizer.py:27
↓ 6 callersMethodconstrain_to_multiple_of
(self, x, min_val=0, max_val=None)
annotator/midas/midas/transforms.py:94
↓ 6 callersFunctionconvert_color_factory
(src, dst)
annotator/uniformer/mmcv/image/colorspace.py:275
next →1–100 of 2,265, ranked by callers