MCPcopy Create free account

hub / github.com/apple/ml-vivid / functions

Functions212 in github.com/apple/ml-vivid

↓ 28 callersMethodget
(self)
training/phema.py:156
↓ 10 callersMethodencode_latents
(self, x)
training/encoders.py:41
↓ 8 callersMethod__init__
(self, img_resolution, # Image resolution. img_channels,
training/models.py:295
↓ 7 callersFunctionall_reduce
(x)
calculate_metrics.py:153
↓ 7 callersMethoddecode
(self, x)
training/encoders.py:44
↓ 7 callersFunctionmp_silu
(x)
training/models.py:64
↓ 7 callersFunctionmp_sum
(a, b, t=0.5)
training/models.py:70
↓ 7 callersFunctionnormalize
(x, dim=None, eps=1e-4)
training/models.py:35
↓ 7 callersMethodrandn
(self, size, **kwargs)
generate_images.py:102
↓ 6 callersMethodflush
Flush written text to both stdout and a file, if open.
dnnlib/util.py:94
↓ 6 callersMethodload
(self, pt_path, verbose=True)
torch_utils/distributed.py:119
↓ 6 callersMethodrandn_like
(self, input)
generate_images.py:106
↓ 6 callersMethodsave
(self, pt_path, verbose=True)
torch_utils/distributed.py:97
↓ 5 callersFunctionexpand_extrinsics
Converts a 3x4 camera matrix to a 4x4
training/utils.py:134
↓ 5 callersMethodinit
(self, device)
training/encoders.py:29
↓ 4 callersFunctionpil_to_tensor
(img)
datautils.py:23
↓ 4 callersFunctionprint0
(*args, **kwargs)
torch_utils/distributed.py:87
↓ 4 callersFunctionrandom_camera_rotation
(image, extrinsics, intrinsics, generator, max_angle_pitch=0, max_angle_yaw=10, max_angle_roll=0)
datautils.py:65
↓ 4 callersFunctionstd_to_exp
(std)
training/phema.py:32
↓ 4 callersFunctiontransform_coordinates
(K, camera_pose, new_size, center_crop_size, old_width=640, old_height=360)
datautils.py:40
↓ 4 callersFunctiontransforms
(im, center_crop_size, imsize)
datautils.py:78
↓ 4 callersMethodupdate
r"""Copies current values of the internal counters to the user-visible state and resets them for the next round. If `keep_previous=Tr
torch_utils/training_stats.py:153
↓ 3 callersMethod_get_delta
r"""Returns the raw moments that were accumulated for the given statistic between the last two calls to `update()`, or zero if no scal
torch_utils/training_stats.py:176
↓ 3 callersFunctionadd_depth
Appends the a predicted depthmap to the given image
training/utils.py:121
↓ 3 callersMethodclose
Flush, close possible files, and remove stdout/stderr mirroring.
dnnlib/util.py:101
↓ 3 callersFunctioncompose_geometry
Stack camera extrinsics and intrinsics into a flattened vector using precomputed statistics. Uses image size to fit the used intrinsics
training/utils.py:64
↓ 3 callersFunctiondecompose_geometry
Unstack camera extrinsics and intrinsics from a flattened vector representation using precomputed statistics. Uses image size to fit the used
training/utils.py:76
↓ 3 callersFunctionget_obj_from_module
Traverses the object name and returns the last (rightmost) python object.
dnnlib/util.py:268
↓ 3 callersMethodload_state_dict
(self, state)
training/phema.py:164
↓ 3 callersMethodmean
r"""Returns the mean of the scalars that were accumulated for the given statistic between the last two calls to `update()`, or NaN if
torch_utils/training_stats.py:194
↓ 3 callersFunctionmp_cat
(a, b, dim=1, t=0.5)
training/models.py:76
↓ 3 callersFunctionnamed_params_and_buffers
(module)
torch_utils/misc.py:158
↓ 3 callersFunctionresolve_model
Loads model from persistent .pkl file
training/utils.py:211
↓ 3 callersMethodupdate
(self, cur_nimg, batch_size)
training/phema.py:147
↓ 2 callersMethod__init__
(self, feature_dim)
calculate_metrics.py:32
↓ 2 callersFunctioncalculate_metrics_from_stats_nvs
( stats, # Feature statistics of the generated images. ref,
calculate_metrics.py:295
↓ 2 callersFunctioncalculate_stats_for_iterable_nvs
( image_iter, # Iterable of image batches: NCHW, uint8, 3 channels. metrics
calculate_metrics.py:134
↓ 2 callersFunctioncompose_K
Stack intrinsic matrices into 4 element vectors
training/utils.py:47
↓ 2 callersFunctiondecompose_K
Unstack intrinsic matrices into 3x3 matrices
training/utils.py:54
↓ 2 callersFunctiondenoise
(x, t)
generate_images.py:53
↓ 2 callersFunctionedm_sampler
( net, src, noise, labels=None, gnet=None, conditioning_image=None, num_steps=32, sigma_min=0.002, sig
generate_images.py:41
↓ 2 callersFunctionget_metrics
Metric computation for training loop
calculate_metrics.py:325
↓ 2 callersFunctionget_module_from_obj_name
Searches for the underlying module behind the name to some python object. Returns the module and the object name (original name with module part r
dnnlib/util.py:227
↓ 2 callersFunctionget_rank
()
torch_utils/distributed.py:57
↓ 2 callersFunctionis_persistent
r"""Test whether the given object or class is persistent, i.e., whether it will save its source code when pickled.
torch_utils/persistence.py:144
↓ 2 callersMethodnames
r"""Returns the names of all statistics broadcasted so far that match the regular expression specified at construction time.
torch_utils/training_stats.py:147
↓ 2 callersFunctionnvs_transforms
(src_image, src_intrinsics, src_extrinsics, tgt_image, tgt_intrinsics, tgt_extrinsics, center_crop_size, imsiz
datautils.py:82
↓ 2 callersFunctionparse_line
(line, width=640, height=360)
datautils.py:27
↓ 2 callersFunctionpower_function_correlation
(a_ofs, a_std, b_ofs, b_std)
training/phema.py:58
↓ 2 callersFunctionreduce
(state, r)
calculate_metrics.py:174
↓ 2 callersFunctionresample
(x, f=[1,1], mode='keep')
training/models.py:46
↓ 2 callersFunctionresolve_depth_model
(depth_model, device=torch.device("cuda"))
training/utils.py:224
↓ 2 callersMethodstate_dict
(self)
training/phema.py:161
↓ 2 callersFunctionsuppress_tracer_warnings
()
torch_utils/misc.py:86
↓ 2 callersMethodwrite
Write text to stdout (and a file) and optionally flush.
dnnlib/util.py:79
↓ 1 callersMethod__getstate__
(self)
training/encoders.py:32
↓ 1 callersMethod__init__
(self)
training/encoders.py:26
↓ 1 callersMethod__reduce__
(self)
torch_utils/persistence.py:129
↓ 1 callersFunction_check_pickleable
r"""Check that the given object is pickleable, raising an exception if it is not. This function is expected to be considerably more efficient
torch_utils/persistence.py:241
↓ 1 callersFunction_module_to_src
r"""Query the source code of a given Python module.
torch_utils/persistence.py:216
↓ 1 callersFunction_src_to_module
r"""Get or create a Python module for the given source code.
torch_utils/persistence.py:226
↓ 1 callersFunction_sync
r"""Synchronize the global cumulative counters across devices and processes. Called internally by `Collector.update()`.
torch_utils/training_stats.py:240
↓ 1 callersMethodas_dict
r"""Returns the averages accumulated between the last two calls to `update()` as an `dnnlib.EasyDict`. The contents are as follows:
torch_utils/training_stats.py:218
↓ 1 callersFunctioncalc_homography_for_rotation
(R, K)
datautils.py:61
↓ 1 callersFunctioncalculate_stats_for_files
( image_path, # Path to a directory or ZIP file containing the images. num_images = N
calculate_metrics.py:256
↓ 1 callersFunctioncall_func_by_name
Finds the python object with the given name and calls it as a function.
dnnlib/util.py:284
↓ 1 callersFunctioncmdline
Generate random images using the given model. Examples: \b # Generate a couple of images and save them as out/*.png python generate_
generate_images.py:308
↓ 1 callersFunctioncmdline
(outdir, dry_run, **opts)
train_nvs.py:195
↓ 1 callersFunctioncmdline
Calculate evaluation metrics (FID and FD_DINOv2). Examples: \b # Generate 10000 images using 8 GPUs and save them as out/*/*.png tor
calculate_metrics.py:354
↓ 1 callersFunctionconstant
(value, shape=None, dtype=None, device=None, memory_format=None)
torch_utils/misc.py:34
↓ 1 callersFunctiondepth_prepare
Transform an image to be used by a DepthAnythingV2 model
training/utils.py:99
↓ 1 callersMethodencode
(self, x)
training/encoders.py:35
↓ 1 callersMethodencode_pixels
(self, x)
training/encoders.py:38
↓ 1 callersFunctiongenerate_images_nvs
( net, # Main network. Path, URL, or torch.nn.Module. gnet
generate_images.py:116
↓ 1 callersFunctiongenerate_rotation_matrix
(generator, max_pitch: float, max_yaw: float, max_roll: float)
datautils.py:49
↓ 1 callersFunctionget_depth
Applies the depth model on the given image and resizes the result to the desired shape
training/utils.py:110
↓ 1 callersFunctionget_detector
(metric, verbose=True)
calculate_metrics.py:102
↓ 1 callersFunctionget_epipolar_attn
(epipolar_corr, epipolar_mixing, patch_size=1)
training/models.py:22
↓ 1 callersFunctionget_epipolar_dist
Computes epipolar distance between two images, for pixels of size 'patch_size' Uses the following formula: Given a line $x=a + t n$, the
training/utils.py:143
↓ 1 callersFunctionget_local_rank
()
torch_utils/distributed.py:52
↓ 1 callersFunctionget_obj_by_name
Finds the python object with the given name.
dnnlib/util.py:278
↓ 1 callersFunctionget_warped_features
(depth, geometry, embedder)
training/utils.py:196
↓ 1 callersFunctionget_world_size
()
torch_utils/distributed.py:62
↓ 1 callersFunctionis_top_level_function
Determine whether the given object is a top-level function, i.e., defined at module scope using 'def'.
dnnlib/util.py:303
↓ 1 callersFunctionis_url
Determine whether the given object is a valid URL string.
dnnlib/util.py:369
↓ 1 callersFunctionlaunch_training
(run_dir, c)
train_nvs.py:109
↓ 1 callersMethodload_latest
(self, run_dir, pattern=r'training-state-(\d+).pt', verbose=True)
torch_utils/distributed.py:141
↓ 1 callersFunctionmake_cache_dir_path
(*paths: str)
dnnlib/util.py:125
↓ 1 callersMethodnum
r"""Returns the number of scalars that were accumulated for the given statistic between the last two calls to `update()`, or zero if n
torch_utils/training_stats.py:186
↓ 1 callersFunctionopen_tensorboard_process
(summary_dir: str)
training/utils.py:24
↓ 1 callersFunctionpersistent_class
r"""Class decorator that extends a given class to save its source code when pickled. Example: from torch_utils import persistence
torch_utils/persistence.py:39
↓ 1 callersFunctionpower_function_beta
(std, t_next, t_delta)
training/phema.py:72
↓ 1 callersFunctionprint_training_config
(run_dir, c)
train_nvs.py:95
↓ 1 callersFunctionrecurse
(obj)
torch_utils/persistence.py:246
↓ 1 callersFunctionreport
r"""Broadcasts the given set of scalars to all interested instances of `Collector`, across device and process boundaries. NaNs and Infs are ig
torch_utils/training_stats.py:59
↓ 1 callersFunctionsetup_training_config
(preset='vivid-base', **opts)
train_nvs.py:36
↓ 1 callersMethodstd
r"""Returns the standard deviation of the scalars that were accumulated for the given statistic between the last two calls to `update(
torch_utils/training_stats.py:204
↓ 1 callersFunctionupdate_mu_sigma
(s, sref, images, tgt, src)
calculate_metrics.py:158
↓ 1 callersFunctionwarp_image
Warps image based on the geometry and the depth
training/utils.py:181
↓ 1 callersFunctionwrap_denoise
()
generate_images.py:48
next →1–100 of 212, ranked by callers