MCPcopy Create free account

hub / github.com/chenhaoxing/HDNet / functions

Functions124 in github.com/chenhaoxing/HDNet

↓ 7 callersFunctionget_act_conv
(act, dims_in, dims_out, kernel, stride, padding, bias)
models/networks.py:151
↓ 7 callersFunctionget_act_dconv
(act, dims_in, dims_out, kernel, stride, padding, bias)
models/networks.py:156
↓ 5 callersFunctionget_norm_layer
Return a normalization layer Parameters: norm_type (str) -- the name of the normalization layer: batch | instance | none For BatchNo
models/networks.py:18
↓ 4 callersFunctioncalculateMean
(vars)
train_evaluate.py:21
↓ 3 callersMethodapply
(module, name, n_power_iterations, dim, eps)
util/spectral_norm.py:109
↓ 3 callersMethodreshape_weight_to_matrix
(self, weight)
util/spectral_norm.py:28
↓ 2 callersMethod__init__
(self, input_nc, output_nc, ngf=64, norm_layer=RAIN, norm_type_indicator=[0, 0, 0, 0, 0, 0,
models/networks.py:162
↓ 2 callersMethodcompute_weight
(self, module, do_power_iteration)
util/spectral_norm.py:37
↓ 2 callersFunctionfind_model_using_name
Import the module "models/[model_name]_model.py". In the file, the class called DatasetNameModel() will be instantiated. It has to be a subcl
models/__init__.py:25
↓ 2 callersMethodforward
(self, x, mask)
models/networks.py:225
↓ 2 callersMethodget_foreground_mean_std
(self, region, mask)
models/normalize.py:33
↓ 2 callersMethodload_data
(self)
data/__init__.py:29
↓ 2 callersFunctionmkdir
create a single empty directory if it didn't exist Parameters: path (str) -- a single directory path
util/util.py:96
↓ 2 callersMethodset_input
Unpack input data from the dataloader and perform necessary pre-processing steps. Parameters: input (dict): includes the data its
models/base_model.py:59
↓ 1 callersFunction__crop
(img, pos, size)
data/base_dataset.py:127
↓ 1 callersMethod__init__
(self, in_channels, out_channels, kernel_size, region_num=2, **kwargs)
models/drconv.py:74
↓ 1 callersFunction__make_power_2
(img, base, method=Image.BICUBIC)
data/base_dataset.py:107
↓ 1 callersMethod__patch_instance_norm_state_dict
Fix InstanceNorm checkpoints incompatibility (prior to 0.4)
models/base_model.py:160
↓ 1 callersFunction__print_size_warning
Print warning information about image size(only print once)
data/base_dataset.py:142
↓ 1 callersFunction__scale_width
(img, target_width, method=Image.BICUBIC)
data/base_dataset.py:118
↓ 1 callersMethod_compose
(self, foreground_img, foreground_mask, background_img)
data/test_dataset.py:79
↓ 1 callersMethod_compose
(self, foreground_img, foreground_mask, background_img)
data/iharmony4_dataset.py:89
↓ 1 callersFunction_get_params
(key)
util/util.py:106
↓ 1 callersMethod_load_images_paths
(self, )
data/test_dataset.py:34
↓ 1 callersMethod_load_images_paths
(self,)
data/iharmony4_dataset.py:28
↓ 1 callersMethod_solve_v_and_rescale
(self, weight_mat, u, target_sigma)
util/spectral_norm.py:101
↓ 1 callersMethod_sort
(self)
data/test_dataset.py:57
↓ 1 callersMethodbackward_G
Calculate GAN and L1 loss for the generator
models/hdnet_model.py:53
↓ 1 callersMethodcompute_visuals
Calculate additional output images for visdom and HTML visualization
models/base_model.py:107
↓ 1 callersFunctioncreate_model
Create a model given the option. This function warps the class CustomDatasetDataLoader. This is the main interface between this package and '
models/__init__.py:54
↓ 1 callersMethodeval
Make models eval mode during test time
models/base_model.py:90
↓ 1 callersFunctionevaluateModel
(epoch_number, model, opt, test_dataset, epoch, max_psnr, iters=None)
train_evaluate.py:29
↓ 1 callersMethodforward
Run forward pass; called by both functions <optimize_parameters> and <test>.
models/base_model.py:68
↓ 1 callersMethodforward
(self)
models/hdnet_model.py:47
↓ 1 callersMethodgather_options
Initialize our parser with basic options(only once). Add additional model-specific and dataset-specific options. These options are def
options/base_options.py:60
↓ 1 callersFunctionget_cfg_defaults
Get a yacs CfgNode object with default values for my_project.
util/config.py:42
↓ 1 callersMethodget_current_losses
Return traning losses / errors. train.py will print out these errors on console, and save them to a file
models/base_model.py:134
↓ 1 callersMethodget_current_visuals
Return visualization images. train.py will display these images with visdom, and save the images to a HTML
models/base_model.py:126
↓ 1 callersFunctionget_transform
(opt, params=None, grayscale=False, method=Image.BICUBIC, convert=True)
data/base_dataset.py:81
↓ 1 callersFunctioninit_net
Initialize a network: 1. register CPU/GPU device (with multi-GPU support); 2. initialize the network weights Parameters: net (network)
models/networks.py:134
↓ 1 callersFunctioninit_weights
Initialize network weights. Parameters: net (network) -- network to be initialized init_type (str) -- the name of an initializa
models/networks.py:101
↓ 1 callersMethodinitialize
Define the common options that are used in both training and test.
options/base_options.py:20
↓ 1 callersMethodload_networks
Load all the networks from the disk. Parameters: epoch (int) -- current epoch; used in the file name '%s_net_%s.pth' % (epoch, na
models/base_model.py:174
↓ 1 callersMethodoptimize_parameters
Calculate losses, gradients, and update network weights; called in every training iteration
models/base_model.py:73
↓ 1 callersMethodparse
Parse our options, create checkpoints directory suffix, and set up gpu device.
options/base_options.py:108
↓ 1 callersFunctionparsePaths
(path)
data/preprocess_iharmony4.py:6
↓ 1 callersMethodprint_networks
Print the total number of parameters in the network and (if verbose) network architecture Parameters: verbose (bool) -- if verbos
models/base_model.py:199
↓ 1 callersMethodprint_options
Print and save options It will print both current options and default values(if different). It will save options into a text file / [
options/base_options.py:83
↓ 1 callersMethodremove
(self, module)
util/spectral_norm.py:89
↓ 1 callersFunctionresolveResults
(results)
train_evaluate.py:81
↓ 1 callersFunctionsave_img
(path, img)
train_evaluate.py:24
↓ 1 callersMethodsave_networks
Save all the networks to the disk. Parameters: epoch (int) -- current epoch; used in the file name '%s_net_%s.pth' % (epoch, name
models/base_model.py:142
↓ 1 callersMethodsetup
Load and print networks; create schedulers Parameters: opt (Option class) -- stores all the experiment flags; needs to be a subcl
models/base_model.py:77
↓ 1 callersMethodtest
Forward function used in test time. This function wraps <forward> function in no_grad() so we don't save intermediate steps for backprop
models/base_model.py:97
↓ 1 callersFunctionupdateWriterInterval
(writer, metrics, epoch)
train_evaluate.py:102
↓ 1 callersFunctionupdate_cfg
(cfg, cfg_file)
util/config.py:48
↓ 1 callersMethodupdate_learning_rate
Update learning rates for all the networks; called at the end of every epoch
models/base_model.py:115
↓ 1 callersFunctionxcorr_fast
group conv2d to calculate cross correlation
models/drconv.py:23
↓ 1 callersFunctionxcorr_slow
for loop to calculate cross correlation
models/drconv.py:7
Method__call__
(self, module, inputs)
util/spectral_norm.py:98
Method__call__
(self, state_dict, prefix, local_metadata, strict, missing_keys, unexpected_keys, error_msgs)
util/spectral_norm.py:158
Method__call__
(self, module, state_dict, prefix, local_metadata)
util/spectral_norm.py:196
Function__flip
(img, flip)
data/base_dataset.py:136
Method__getitem__
(self, index)
data/test_dataset.py:63
Method__getitem__
(self, index)
data/iharmony4_dataset.py:68
Method__getitem__
Return a data point and its metadata information. Parameters: index - - a random integer for data indexing Returns:
data/base_dataset.py:51
Method__init__
foreground_paths: [folder, imagepath_list, image path] mask_paths: [folter, imagepath_list, image path] background_paths:
data/test_dataset.py:9
Method__init__
Initialize this dataset class. Parameters: opt (Option class) -- stores all the experiment flags; needs to be a subclass of BaseOp
data/iharmony4_dataset.py:12
Method__init__
Initialize the class; save the options in the class Parameters: opt (Option class)-- stores all the experiment flags; needs to be
data/base_dataset.py:23
Method__init__
(self, opt, is_for_train)
data/__init__.py:14
Method__init__
Reset the class; indicates the class hasn't been initailized
options/base_options.py:16
Method__init__
(self, use_slow=None)
models/drconv.py:53
Method__init__
Initialize the BaseModel class. Parameters: opt (Option class)-- stores all the experiment flags; needs to be a subclass of BaseO
models/base_model.py:17
Method__init__
(self, opt)
models/hdnet_model.py:11
Method__init__
Compute the instance normalization within only the background region, in which the mean and standard variance are measured from the featur
models/normalize.py:6
Method__init__
Construct a Unet submodule with skip connections. Parameters: outer_nc (int) -- the number of filters in the outer conv layer
models/networks.py:341
Method__init__
(self, *args, **kwargs)
models/networks.py:439
Method__init__
(self, dims_in)
models/att.py:6
Method__init__
(self, min_area=100)
models/fMSE.py:5
Method__init__
Initialize the ImagePool class Parameters: pool_size (int) -- the size of image buffer, if pool_size=0, no buffer will be created
util/image_pool.py:12
Method__init__
(self, name='weight', n_power_iterations=1, dim=0, eps=1e-12)
util/spectral_norm.py:19
Method__init__
(self, fn)
util/spectral_norm.py:147
Method__init__
(self, fn)
util/spectral_norm.py:193
Method__len__
Return the total number of images.
data/test_dataset.py:75
Method__len__
Return the total number of images.
data/iharmony4_dataset.py:85
Method__len__
Return the total number of images in the dataset.
data/base_dataset.py:46
Method__len__
(self)
data/__init__.py:32
Functioncopy_state_dict
(cur_state_dict, pre_state_dict, prefix='', load_name=None)
util/util.py:105
Functiondefine_G
load a generator Parameters: input_nc (int) -- the number of channels in input images output_nc (int) -- the number of channels i
models/networks.py:41
Functiondiagnose_network
Calculate and print the mean of average absolute(gradients) Parameters: net (torch network) -- Torch network name (str) -- the na
util/util.py:30
Methodextra_repr
(self)
models/drconv.py:60
Methodforward
group conv2d to calculate cross correlation
models/drconv.py:39
Methodforward
(self, x, kernel, **kwargs)
models/drconv.py:64
Methodforward
(self, input, mask)
models/drconv.py:89
Methodforward
(self, x, mask)
models/normalize.py:17
Methodforward
(self, x)
models/networks.py:15
Methodforward
(self, x, mask)
models/networks.py:402
Methodforward
(self, input, mask_in=None)
models/networks.py:465
Methodforward
(self, x, mask)
models/att.py:12
Methodforward
(self, pred, label, mask)
models/fMSE.py:9
next →1–100 of 124, ranked by callers