Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/TianheWu/CoSeR
/ functions
Functions
1,666 in github.com/TianheWu/CoSeR
⨍
Functions
1,666
◇
Types & classes
358
↳
Endpoints
1
Method
shared_step
(self, batch, **kwargs)
ldm/models/diffusion/ddpm.py:1029
Method
shared_step
(self, batch, **kwargs)
ldm/models/diffusion/ddpm.py:2520
Method
shared_step
(self, batch, **kwargs)
ldm/models/diffusion/ddpm_inv.py:905
Function
shave
(img_in, border=0)
ldm/modules/image_degradation/utils_image.py:510
Function
single2tensor3
(img)
ldm/modules/image_degradation/utils_image.py:302
Function
single2tensor4
(img)
ldm/modules/image_degradation/utils_image.py:307
Function
single2tensor5
(img)
ldm/modules/image_degradation/utils_image.py:329
Function
single2uint
(img)
ldm/modules/image_degradation/utils_image.py:254
Function
single2uint16
(img)
ldm/modules/image_degradation/utils_image.py:264
Function
single32tensor5
(img)
ldm/modules/image_degradation/utils_image.py:333
Function
single42tensor4
(img)
ldm/modules/image_degradation/utils_image.py:337
Function
smooth_data
Smooth data using 1st-order IIR low-pass filter (what tensorflow does). Reference: https://github.com/tensorflow/tensorboard/blob/f801ebf1f9fbfe
basicsr/utils/plot_util.py:68
Function
space_timesteps
Create a list of timesteps to use from an original diffusion process, given the number of timesteps we want to take from equally-sized portio
ldm/models/respace.py:7
Function
space_timesteps
Create a list of timesteps to use from an original diffusion process, given the number of timesteps we want to take from equally-sized portio
ldm/models/diffusion/ddim.py:13
Function
split_imageset
split the large images from original_dataroot into small overlapped images with size (p_size)x(p_size), and save them into taget_dataroot; on
ldm/modules/image_degradation/utils_image.py:125
Function
srmd_degradation
blur + bicubic downsampling Args: x: HxWxC image, [0, 1] k: hxw, double sf: down-scale factor Return: downsam
ldm/modules/image_degradation/bsrgan_light.py:240
Function
srmd_degradation
blur + bicubic downsampling Args: x: HxWxC image, [0, 1] k: hxw, double sf: down-scale factor Return: downsam
ldm/modules/image_degradation/bsrgan.py:240
Method
stochastic_encode
(self, x0, t, use_original_steps=False, noise=None)
ldm/models/diffusion/ddim.py:271
Function
str2bool
(v)
main.py:28
Function
string_begins_with
(prefix, str)
ldm/modules/x_transformer.py:102
Function
surf
(Z, cmap='rainbow', figsize=None)
ldm/modules/image_degradation/utils_image.py:47
Function
tensor2img
Convert torch Tensors into image numpy arrays. After clamping to [min, max], values will be normalized to [0, 1]. Args: tensor (Tens
scripts/util_image.py:216
Function
tensor2img
Converts a torch Tensor into an image Numpy array of BGR channel order Input: 4D(B,(3/1),H,W), 3D(C,H,W), or 2D(H,W), any range, RGB channel
ldm/modules/image_degradation/utils_image.py:342
Function
tensor2img_fast
This implementation is slightly faster than tensor2img. It now only supports torch tensor with shape (1, c, h, w). Args: tensor (Tens
basicsr/utils/img_util.py:97
Function
tensor2single
(img)
ldm/modules/image_degradation/utils_image.py:312
Function
tensor2single3
(img)
ldm/modules/image_degradation/utils_image.py:320
Function
tensor2uint
(img)
ldm/modules/image_degradation/utils_image.py:289
Method
test
(self)
basicsr/models/swinir_model.py:11
Method
test_selfensemble
(self)
basicsr/models/sr_model.py:132
Method
to_rgb
(self, x)
ldm/models/diffusion/ddpm.py:3449
Method
to_rgb
(self, x)
ldm/models/diffusion/ddpm.py:4080
Function
torch2img
(input)
ldm/models/diffusion/ddpm.py:49
Method
training_step
(self, batch, batch_idx, optimizer_idx)
ldm/models/autoencoder.py:150
Method
training_step
(self, batch, batch_idx, optimizer_idx)
ldm/models/autoencoder.py:376
Method
training_step
(self, batch, batch_idx, optimizer_idx)
ldm/models/autoencoder.py:834
Method
training_step
(self, batch, batch_idx)
ldm/models/diffusion/classifier.py:198
Method
training_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm.py:487
Method
training_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm.py:3985
Method
training_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm_inv.py:351
Function
triplet_random_crop
(img_gts, img_lqs, img_segs, gt_patch_size, scale, gt_path=None)
basicsr/data/transforms.py:93
Function
uint162single
(img)
ldm/modules/image_degradation/utils_image.py:259
Function
uint2single
(img)
ldm/modules/image_degradation/utils_image.py:249
Function
uint2tensor3
(img)
ldm/modules/image_degradation/utils_image.py:282
Function
uint2tensor4
(img)
ldm/modules/image_degradation/utils_image.py:275
Function
uniform_on_device
(r1, r2, shape, device)
ldm/models/diffusion/ddpm.py:161
Function
uniform_on_device
(r1, r2, shape, device)
ldm/models/diffusion/ddpm_inv.py:42
Function
uniq
(arr)
ldm/modules/attention.py:25
Function
usm_sharp
USM sharpening. Input image: I; Blurry image: B. 1. sharp = I + weight * (I - B) 2. Mask = 1 if abs(I - B) > threshold, else: 0 3. Bl
basicsr/utils/img_process_util.py:34
Method
validation
Warning: HiFaceGAN requires train() mode even for validation For more info, see https://github.com/Lotayou/Face-Renovation/issues/31
basicsr/models/hifacegan_model.py:194
Method
validation_step
(self, batch, batch_idx)
ldm/models/autoencoder.py:172
Method
validation_step
(self, batch, batch_idx)
ldm/models/autoencoder.py:397
Method
validation_step
(self, batch, batch_idx)
ldm/models/autoencoder.py:858
Method
validation_step
(self, batch, batch_idx)
ldm/models/diffusion/classifier.py:210
Method
validation_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm.py:503
Method
validation_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm.py:2031
Method
validation_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm.py:3997
Method
validation_step
(self, batch, batch_idx)
ldm/models/diffusion/ddpm_inv.py:367
Function
wavelet_color_fix
(target: Image, source: Image)
scripts/wavelet_color_fix.py:29
Function
weighted_loss
Create a weighted version of a given loss function. To use this decorator, the loss function must have the signature like `loss_func(pred, ta
basicsr/losses/loss_util.py:58
Function
worker_init_fn
(_)
main.py:155
Function
worker_init_fn
(worker_id, num_workers, rank, seed)
basicsr/data/__init__.py:97
Function
wrapper
(*args, **kwargs)
basicsr/utils/dist_util.py:77
Function
wrapper
(pred, target, weight=None, reduction='mean', **kwargs)
basicsr/losses/loss_util.py:90
Function
ycbcr2bgr
Convert a YCbCr image to BGR image. The bgr version of ycbcr2rgb. It implements the ITU-R BT.601 conversion for standard-definition telev
basicsr/utils/color_util.py:100
Function
ycbcr2rgb
Convert a YCbCr image to RGB image. This function produces the same results as Matlab's ycbcr2rgb function. It implements the ITU-R BT.601 co
basicsr/utils/color_util.py:71
Function
ycbcr2rgb
same as matlab ycbcr2rgb Input: uint8, [0, 255] float, [0, 1]
ldm/modules/image_degradation/utils_image.py:553
← previous
1,601–1,666 of 1,666, ranked by callers