SYMBOL INDEX (411 symbols across 37 files) FILE: inference_ctrl.py function preprocess (line 45) | def preprocess(video_path, image_path, dift_model_path, resolution=576, ... function run_pipeline (line 150) | def run_pipeline(pipeline, image_pixels, pose_pixels, function main (line 176) | def main(args): function set_logger (line 203) | def set_logger(log_file=None, log_level=logging.INFO): FILE: mimicmotion/dwpose/dwpose_detector.py class DWposeDetector (line 11) | class DWposeDetector: method __init__ (line 22) | def __init__(self, model_det, model_pose, device='cpu'): method release_memory (line 25) | def release_memory(self): method __call__ (line 30) | def __call__(self, oriImg): FILE: mimicmotion/dwpose/onnxdet.py function nms (line 5) | def nms(boxes, scores, nms_thr): function multiclass_nms (line 43) | def multiclass_nms(boxes, scores, nms_thr, score_thr): function demo_postprocess (line 76) | def demo_postprocess(outputs, img_size, p6=False): function preprocess (line 98) | def preprocess(img, input_size, swap=(2, 0, 1)): function inference_detector (line 116) | def inference_detector(session, oriImg): FILE: mimicmotion/dwpose/onnxpose.py function preprocess (line 7) | def preprocess( function inference (line 52) | def inference(sess: ort.InferenceSession, img: np.ndarray) -> np.ndarray: function postprocess (line 80) | def postprocess(outputs: List[np.ndarray], function bbox_xyxy2cs (line 115) | def bbox_xyxy2cs(bbox: np.ndarray, function _fix_aspect_ratio (line 149) | def _fix_aspect_ratio(bbox_scale: np.ndarray, function _rotate_point (line 167) | def _rotate_point(pt: np.ndarray, angle_rad: float) -> np.ndarray: function _get_3rd_point (line 182) | def _get_3rd_point(a: np.ndarray, b: np.ndarray) -> np.ndarray: function get_warp_matrix (line 201) | def get_warp_matrix(center: np.ndarray, function top_down_affine (line 255) | def top_down_affine(input_size: dict, bbox_scale: dict, bbox_center: dict, function get_simcc_maximum (line 288) | def get_simcc_maximum(simcc_x: np.ndarray, function decode (line 333) | def decode(simcc_x: np.ndarray, simcc_y: np.ndarray, function inference_pose (line 353) | def inference_pose(session, out_bbox, oriImg): FILE: mimicmotion/dwpose/preprocess.py function get_video_pose (line 8) | def get_video_pose( function get_image_pose (line 64) | def get_image_pose(ref_image): FILE: mimicmotion/dwpose/util.py function alpha_blend_color (line 9) | def alpha_blend_color(color, alpha): function draw_bodypose (line 14) | def draw_bodypose(canvas, candidate, subset, score): function draw_handpose (line 59) | def draw_handpose(canvas, all_hand_peaks, all_hand_scores): function draw_facepose (line 88) | def draw_facepose(canvas, all_lmks, all_scores): function draw_pose (line 100) | def draw_pose(pose, H, W, ref_w=2160): FILE: mimicmotion/dwpose/wholebody.py class Wholebody (line 8) | class Wholebody: method __init__ (line 11) | def __init__(self, model_det, model_pose, device="cpu"): method __call__ (line 22) | def __call__(self, oriImg): FILE: mimicmotion/modules/attention.py class TransformerTemporalModelOutput (line 18) | class TransformerTemporalModelOutput(BaseOutput): class TransformerTemporalModel (line 30) | class TransformerTemporalModel(ModelMixin, ConfigMixin): method __init__ (line 60) | def __init__( method forward (line 110) | def forward( class TransformerSpatioTemporalModel (line 191) | class TransformerSpatioTemporalModel(nn.Module): method __init__ (line 206) | def __init__( method forward (line 266) | def forward( function exists (line 387) | def exists(val): function uniq (line 391) | def uniq(arr): function default (line 395) | def default(val, d): function max_neg_value (line 401) | def max_neg_value(t): function init_ (line 405) | def init_(tensor): class GEGLU (line 413) | class GEGLU(nn.Module): method __init__ (line 414) | def __init__(self, dim_in, dim_out): method forward (line 418) | def forward(self, x): class FeedForward (line 423) | class FeedForward(nn.Module): method __init__ (line 424) | def __init__(self, dim, dim_out=None, mult=4, glu=False, dropout=0.): method forward (line 439) | def forward(self, x): function zero_module (line 443) | def zero_module(module): function Normalize (line 452) | def Normalize(in_channels): class LinearAttention (line 456) | class LinearAttention(nn.Module): method __init__ (line 457) | def __init__(self, dim, heads=4, dim_head=32): method forward (line 464) | def forward(self, x): class SpatialSelfAttention (line 475) | class SpatialSelfAttention(nn.Module): method __init__ (line 476) | def __init__(self, in_channels): method forward (line 502) | def forward(self, x): class CrossAttention (line 528) | class CrossAttention(nn.Module): method __init__ (line 529) | def __init__(self, query_dim, context_dim=None, heads=8, dim_head=64, ... method forward (line 546) | def forward(self, x, context=None, mask=None): class BasicTransformerBlock (line 572) | class BasicTransformerBlock(nn.Module): method __init__ (line 573) | def __init__(self, dim, n_heads, d_head, dropout=0., context_dim=None,... method forward (line 583) | def forward(self, x, context=None): class SpatialTransformer (line 590) | class SpatialTransformer(nn.Module): method __init__ (line 598) | def __init__(self, in_channels, n_heads=8, d_head=64, method forward (line 622) | def forward(self, x, context=None): FILE: mimicmotion/modules/cmp/losses.py function MultiChannelSoftBinaryCrossEntropy (line 9) | def MultiChannelSoftBinaryCrossEntropy(input, target, reduction='mean'): class EdgeAwareLoss (line 23) | class EdgeAwareLoss(): method __init__ (line 24) | def __init__(self, nc=2, loss_type="L1", reduction='mean'): method bce2d (line 39) | def bce2d(self, input, target): method get_edge (line 46) | def get_edge(self, var): method __call__ (line 54) | def __call__(self, input, target): function KLD (line 66) | def KLD(mean, logvar): class DiscreteLoss (line 69) | class DiscreteLoss(nn.Module): method __init__ (line 70) | def __init__(self, nbins, fmax): method tobin (line 78) | def tobin(self, target): method __call__ (line 83) | def __call__(self, input, target): class MultiDiscreteLoss (line 95) | class MultiDiscreteLoss(): method __init__ (line 96) | def __init__(self, nbins=19, fmax=47.5, reduction='mean', xy_weight=(1... method tobin (line 105) | def tobin(self, target): method __call__ (line 116) | def __call__(self, input, target): class MultiL1Loss (line 126) | class MultiL1Loss(): method __init__ (line 127) | def __init__(self, reduction='mean'): method __call__ (line 130) | def __call__(self, input, target): class MultiMSELoss (line 139) | class MultiMSELoss(): method __init__ (line 140) | def __init__(self): method __call__ (line 143) | def __call__(self, predicts, targets): class JointDiscreteLoss (line 149) | class JointDiscreteLoss(): method __init__ (line 150) | def __init__(self, nbins=19, fmax=47.5, reduction='mean', quantize_str... method tobin (line 158) | def tobin(self, target): method __call__ (line 172) | def __call__(self, input, target): class PolarDiscreteLoss (line 177) | class PolarDiscreteLoss(): method __init__ (line 178) | def __init__(self, abins=30, rbins=20, fmax=50., reduction='mean', ar_... method tobin (line 186) | def tobin(self, target): method __call__ (line 207) | def __call__(self, input, target): class WeightedDiscreteLoss (line 212) | class WeightedDiscreteLoss(): method __init__ (line 213) | def __init__(self, nbins=19, fmax=47.5, reduction='mean'): method tobin (line 223) | def tobin(self, target): method __call__ (line 227) | def __call__(self, input, target): class CrossEntropy2d (line 233) | class CrossEntropy2d(nn.Module): method __init__ (line 234) | def __init__(self, reduction='mean', ignore_label=-1): method forward (line 239) | def forward(self, predict, target, weight=None): class CrossPixelSimilarityLoss (line 323) | class CrossPixelSimilarityLoss(): method __init__ (line 327) | def __init__(self, sigma=0.01, sampling_size=512): method __call__ (line 333) | def __call__(self, embeddings, flows): class CrossPixelSimilarityFullLoss (line 386) | class CrossPixelSimilarityFullLoss(): method __init__ (line 390) | def __init__(self, sigma=0.01): method __call__ (line 395) | def __call__(self, embeddings, flows): function get_column (line 453) | def get_column(embeddings, index, full_size): class CrossPixelSimilarityColumnLoss (line 460) | class CrossPixelSimilarityColumnLoss(nn.Module): method __init__ (line 464) | def __init__(self, sigma=0.0036, sampling_size=512): method forward (line 475) | def forward(self, feats, flows): function print_info (line 526) | def print_info(name, var): function MaskL1Loss (line 530) | def MaskL1Loss(input, target, mask): FILE: mimicmotion/modules/cmp/models/backbone/alexnet.py class AlexNetBN_FCN (line 4) | class AlexNetBN_FCN(nn.Module): method __init__ (line 6) | def __init__(self, output_dim=256, stride=[4, 2, 2, 2], dilation=[1, 1... method forward (line 57) | def forward(self, x, ret_feat=False): function alexnet_fcn_32x (line 75) | def alexnet_fcn_32x(output_dim, pretrained=False, **kwargs): function alexnet_fcn_8x (line 80) | def alexnet_fcn_8x(output_dim, use_ppm=False, pretrained=False, **kwargs): FILE: mimicmotion/modules/cmp/models/backbone/resnet.py function conv3x3 (line 17) | def conv3x3(in_planes, out_planes, stride=1): class BasicBlock (line 23) | class BasicBlock(nn.Module): method __init__ (line 26) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 36) | def forward(self, x): class Bottleneck (line 55) | class Bottleneck(nn.Module): method __init__ (line 58) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 71) | def forward(self, x): class ResNet (line 94) | class ResNet(nn.Module): method __init__ (line 96) | def __init__(self, output_dim, block, layers): method _make_layer (line 136) | def _make_layer(self, block, planes, blocks, stride=1): method forward (line 153) | def forward(self, img, ret_feat=False): function resnet18 (line 170) | def resnet18(output_dim, pretrained=False): function resnet34 (line 177) | def resnet34(output_dim, pretrained=False): function resnet50 (line 184) | def resnet50(output_dim, pretrained=False): function resnet101 (line 190) | def resnet101(output_dim, pretrained=False): function resnet152 (line 197) | def resnet152(output_dim, pretrained=False): FILE: mimicmotion/modules/cmp/models/cmp.py class CMP (line 9) | class CMP(SingleStageModel): method __init__ (line 11) | def __init__(self, params, dist_model=False): method eval (line 30) | def eval(self, ret_loss=True): method step (line 57) | def step(self): FILE: mimicmotion/modules/cmp/models/modules/cmp.py class CMP (line 6) | class CMP(nn.Module): method __init__ (line 8) | def __init__(self, params): method forward (line 27) | def forward(self, image, sparse): FILE: mimicmotion/modules/cmp/models/modules/decoder.py class MotionDecoderPlain (line 5) | class MotionDecoderPlain(nn.Module): method __init__ (line 7) | def __init__(self, input_dim=512, output_dim=2, combo=[1,2,4]): method forward (line 69) | def forward(self, x): class MotionDecoderSkipLayer (line 96) | class MotionDecoderSkipLayer(nn.Module): method __init__ (line 98) | def __init__(self, input_dim=512, output_dim=2, combo=[1,2,4,8]): method forward (line 188) | def forward(self, x, skip_feat): class MotionDecoderFlowNet (line 218) | class MotionDecoderFlowNet(nn.Module): method __init__ (line 220) | def __init__(self, input_dim=512, output_dim=2, combo=[1,2,4,8]): method forward (line 308) | def forward(self, x, skip_feat): function predict_flow (line 346) | def predict_flow(in_planes, out_planes): function deconv (line 351) | def deconv(in_planes, out_planes): FILE: mimicmotion/modules/cmp/models/modules/others.py class FixModule (line 3) | class FixModule(nn.Module): method __init__ (line 5) | def __init__(self, m): method forward (line 9) | def forward(self, *args, **kwargs): FILE: mimicmotion/modules/cmp/models/modules/shallownet.py class ShallowNet (line 4) | class ShallowNet(nn.Module): method __init__ (line 6) | def __init__(self, input_dim=4, output_dim=16, stride=[2, 2, 2]): method forward (line 35) | def forward(self, x): function shallownet8x (line 40) | def shallownet8x(output_dim): function shallownet32x (line 44) | def shallownet32x(output_dim, **kwargs): FILE: mimicmotion/modules/cmp/models/modules/warp.py class WarpingLayerBWFlow (line 4) | class WarpingLayerBWFlow(nn.Module): method __init__ (line 6) | def __init__(self): method forward (line 9) | def forward(self, image, flow): class WarpingLayerFWFlow (line 28) | class WarpingLayerFWFlow(nn.Module): method __init__ (line 30) | def __init__(self): method forward (line 34) | def forward(self, image, flow, ret_mask = False): FILE: mimicmotion/modules/cmp/models/single_stage_model.py class SingleStageModel (line 10) | class SingleStageModel(object): method __init__ (line 12) | def __init__(self, params, dist_model=False): method set_input (line 37) | def set_input(self, image_input, sparse_input, flow_target=None, rgb_t... method eval (line 43) | def eval(self, ret_loss=True): method step (line 46) | def step(self): method load_state (line 49) | def load_state(self, path, Iter, resume=False): method load_pretrain (line 57) | def load_pretrain(self, load_path): method save_state (line 60) | def save_state(self, path, Iter): method switch_to (line 68) | def switch_to(self, phase): FILE: mimicmotion/modules/cmp/utils/common_utils.py function init_weights (line 8) | def init_weights(net, init_type='normal', init_gain=0.02): function create_logger (line 38) | def create_logger(name, log_file, level=logging.INFO): class AverageMeter (line 50) | class AverageMeter(object): method __init__ (line 52) | def __init__(self, length=0): method reset (line 56) | def reset(self): method update (line 65) | def update(self, val): function accuracy (line 79) | def accuracy(output, target, topk=(1,)): function load_state (line 94) | def load_state(path, model, optimizer=None): FILE: mimicmotion/modules/cmp/utils/data_utils.py function get_edge (line 10) | def get_edge(data, blur=False): function get_max (line 21) | def get_max(score, bbox): function nms (line 28) | def nms(score, ks): function image_flow_crop (line 35) | def image_flow_crop(img1, img2, flow, crop_size, phase): function image_crop (line 61) | def image_crop(img, crop_size): function image_flow_resize (line 73) | def image_flow_resize(img1, img2, flow, short_size=None, long_size=None): function image_resize (line 96) | def image_resize(img, short_size=None, long_size=None): function image_pose_crop (line 117) | def image_pose_crop(img, posemap, crop_size, scale): function neighbor_elim (line 127) | def neighbor_elim(ph, pw, d): function remove_border (line 141) | def remove_border(mask): function flow_sampler (line 147) | def flow_sampler(flow, strategy=['grid'], bg_ratio=1./6400, nms_ks=15, m... function image_flow_aug (line 226) | def image_flow_aug(img1, img2, flow, flip_horizon=True): function flow_aug (line 235) | def flow_aug(flow, reverse=True, scale=True, rotate=True): function draw_gaussian (line 250) | def draw_gaussian(img, pt, sigma, type='Gaussian'): FILE: mimicmotion/modules/cmp/utils/distributed_utils.py class DistModule (line 12) | class DistModule(Module): method __init__ (line 13) | def __init__(self, module): method forward (line 17) | def forward(self, *inputs, **kwargs): method train (line 19) | def train(self, mode=True): function average_gradients (line 23) | def average_gradients(model): function broadcast_params (line 29) | def broadcast_params(model): function dist_init (line 34) | def dist_init(launcher, backend='nccl', **kwargs): function _init_dist_pytorch (line 46) | def _init_dist_pytorch(backend, **kwargs): function _init_dist_mpi (line 52) | def _init_dist_mpi(backend, **kwargs): function _init_dist_slurm (line 55) | def _init_dist_slurm(backend, port=10086, **kwargs): function gather_tensors (line 69) | def gather_tensors(input_array): function gather_tensors_batch (line 93) | def gather_tensors_batch(input_array, part_size=10): function reduce_tensors (line 108) | def reduce_tensors(tensor): class DistributedSequentialSampler (line 113) | class DistributedSequentialSampler(Sampler): method __init__ (line 114) | def __init__(self, dataset, world_size=None, rank=None): method __iter__ (line 129) | def __iter__(self): method __len__ (line 133) | def __len__(self): class GivenIterationSampler (line 136) | class GivenIterationSampler(Sampler): method __init__ (line 137) | def __init__(self, dataset, total_iter, batch_size, last_iter=-1): method __iter__ (line 147) | def __iter__(self): method gen_new_list (line 154) | def gen_new_list(self): method __len__ (line 172) | def __len__(self): class DistributedGivenIterationSampler (line 176) | class DistributedGivenIterationSampler(Sampler): method __init__ (line 177) | def __init__(self, dataset, total_iter, batch_size, world_size=None, r... method __iter__ (line 195) | def __iter__(self): method gen_new_list (line 202) | def gen_new_list(self): method __len__ (line 222) | def __len__(self): FILE: mimicmotion/modules/cmp/utils/flowlib.py function write_flow (line 25) | def write_flow(flow, filename): function save_flow_image (line 44) | def save_flow_image(flow, image_file): function segment_flow (line 55) | def segment_flow(flow): function flow_to_image (line 91) | def flow_to_image(flow): function disp_to_flowfile (line 129) | def disp_to_flowfile(disp, filename): function compute_color (line 149) | def compute_color(u, v): function make_color_wheel (line 193) | def make_color_wheel(): function read_flo_file (line 243) | def read_flo_file(filename, memcached=False): function resample (line 268) | def resample(img, sz): FILE: mimicmotion/modules/cmp/utils/scheduler.py class _LRScheduler (line 4) | class _LRScheduler(object): method __init__ (line 5) | def __init__(self, optimizer, last_iter=-1): method _get_new_lr (line 21) | def _get_new_lr(self): method get_lr (line 24) | def get_lr(self): method step (line 27) | def step(self, this_iter=None): class _WarmUpLRSchedulerOld (line 34) | class _WarmUpLRSchedulerOld(_LRScheduler): method __init__ (line 36) | def __init__(self, optimizer, base_lr, warmup_lr, warmup_steps, last_i... method _get_warmup_lr (line 45) | def _get_warmup_lr(self): class _WarmUpLRScheduler (line 54) | class _WarmUpLRScheduler(_LRScheduler): method __init__ (line 56) | def __init__(self, optimizer, base_lr, warmup_lr, warmup_steps, last_i... method _get_warmup_lr (line 65) | def _get_warmup_lr(self): class StepLRScheduler (line 77) | class StepLRScheduler(_WarmUpLRScheduler): method __init__ (line 78) | def __init__(self, optimizer, milestones, lr_mults, base_lr, warmup_lr... method _get_new_lr (line 92) | def _get_new_lr(self): FILE: mimicmotion/modules/cmp/utils/visualize_utils.py class Fuser (line 6) | class Fuser(object): method __init__ (line 7) | def __init__(self, nbins, fmax): method convert_flow (line 13) | def convert_flow(self, flow_prob): function visualize_tensor_old (line 21) | def visualize_tensor_old(image, mask, flow_pred, flow_target, warped, rg... function visualize_tensor (line 35) | def visualize_tensor(image, mask, flow_tensors, common_tensors, rgb_tens... function unormalize (line 48) | def unormalize(tensor, mean, div): function flow_to_image (line 54) | def flow_to_image(flow): function shift_tensor (line 59) | def shift_tensor(input, offh, offw): function draw_block (line 66) | def draw_block(mask, radius=5): function expand_block (line 80) | def expand_block(sparse, radius=5): function draw_cross (line 92) | def draw_cross(tensor, mask, radius=5, thickness=2): FILE: mimicmotion/modules/cmp_model.py class ArgObj (line 19) | class ArgObj(object): method __init__ (line 20) | def __init__(self): class CMP (line 24) | class CMP(nn.Module): method __init__ (line 25) | def __init__(self, configfn, load_iter): method run (line 49) | def run(self, image, sparse, mask): FILE: mimicmotion/modules/controlnet.py function exists (line 43) | def exists(val): function default (line 46) | def default(val, d): class ControlNetOutput (line 52) | class ControlNetOutput(BaseOutput): class ControlNetConditioningEmbeddingSVD (line 71) | class ControlNetConditioningEmbeddingSVD(nn.Module): method __init__ (line 81) | def __init__( method forward (line 123) | def forward(self, flow_conditioning, traj_conditioning): class ControlNetSVDModel (line 158) | class ControlNetSVDModel(ModelMixin, ConfigMixin, FromOriginalControlNet... method __init__ (line 196) | def __init__( method attn_processors (line 353) | def attn_processors(self) -> Dict[str, AttentionProcessor]: method set_attn_processor (line 380) | def set_attn_processor(self, processor: Union[AttentionProcessor, Dict... method set_default_attn_processor (line 414) | def set_default_attn_processor(self): method _set_gradient_checkpointing (line 427) | def _set_gradient_checkpointing(self, module, value=False): method enable_forward_chunking (line 432) | def enable_forward_chunking(self, chunk_size: Optional[int] = None, di... method forward (line 461) | def forward( method from_unet (line 622) | def from_unet( method attn_processors (line 681) | def attn_processors(self) -> Dict[str, AttentionProcessor]: method set_attn_processor (line 705) | def set_attn_processor( method set_default_attn_processor (line 742) | def set_default_attn_processor(self): method set_attention_slice (line 758) | def set_attention_slice(self, slice_size: Union[str, int, List[int]]) ... function zero_module (line 828) | def zero_module(module): FILE: mimicmotion/modules/point_adapter.py class MLP (line 12) | class MLP(nn.Module): method __init__ (line 13) | def __init__(self, in_dim, out_dim, mid_dim=128): method forward (line 21) | def forward(self, x): function vectorized_bilinear_interpolation (line 24) | def vectorized_bilinear_interpolation(level_adapter_state, coords, frame... function bilinear_interpolation (line 54) | def bilinear_interpolation(level_adapter_state, x, y, frame_idx, interpo... class PointAdapter (line 78) | class PointAdapter(nn.Module): method __init__ (line 80) | def __init__( method generate_loss_mask (line 99) | def generate_loss_mask(self, batch_size, point_tracker, num_frames, h,... method forward (line 128) | def forward(self, point_tracker, size, point_embedding, pose_latents, ... FILE: mimicmotion/modules/pose_net.py class PoseNet (line 10) | class PoseNet(nn.Module): method __init__ (line 13) | def __init__(self, noise_latent_channels=320, *args, **kwargs): method _initialize_weights (line 46) | def _initialize_weights(self): method forward (line 59) | def forward(self, x): method from_pretrained (line 68) | def from_pretrained(cls, pretrained_model_path): FILE: mimicmotion/modules/unet.py class UNetSpatioTemporalConditionOutput (line 19) | class UNetSpatioTemporalConditionOutput(BaseOutput): class UNetSpatioTemporalConditionModel (line 31) | class UNetSpatioTemporalConditionModel(ModelMixin, ConfigMixin, UNet2DCo... method __init__ (line 72) | def __init__( method attn_processors (line 255) | def attn_processors(self) -> Dict[str, AttentionProcessor]: method set_attn_processor (line 282) | def set_attn_processor(self, processor: Union[AttentionProcessor, Dict... method set_default_attn_processor (line 316) | def set_default_attn_processor(self): method _set_gradient_checkpointing (line 330) | def _set_gradient_checkpointing(self, module, value=False): method enable_forward_chunking (line 335) | def enable_forward_chunking(self, chunk_size: Optional[int] = None, di... method forward (line 364) | def forward( FILE: mimicmotion/pipelines/pipeline_ctrl.py function _append_dims (line 30) | def _append_dims(x, target_dims): function tensor2vid (line 39) | def tensor2vid(video: torch.Tensor, processor: "VaeImageProcessor", outp... class MimicMotionPipelineOutput (line 61) | class MimicMotionPipelineOutput(BaseOutput): class Ctrl_Pipeline (line 74) | class Ctrl_Pipeline(DiffusionPipeline): method __init__ (line 100) | def __init__( method _encode_image (line 124) | def _encode_image( method _encode_pose_image (line 171) | def _encode_pose_image( method _encode_vae_image (line 189) | def _encode_vae_image( method _get_add_time_ids (line 212) | def _get_add_time_ids( method decode_latents (line 242) | def decode_latents( method check_inputs (line 275) | def check_inputs(self, image, height, width): method prepare_latents (line 289) | def prepare_latents( method guidance_scale (line 324) | def guidance_scale(self): method do_classifier_free_guidance (line 331) | def do_classifier_free_guidance(self): method num_timesteps (line 337) | def num_timesteps(self): method prepare_extra_step_kwargs (line 340) | def prepare_extra_step_kwargs(self, generator, eta): method __call__ (line 358) | def __call__( FILE: mimicmotion/pipelines/pipeline_mimicmotion.py function _append_dims (line 25) | def _append_dims(x, target_dims): function tensor2vid (line 34) | def tensor2vid(video: torch.Tensor, processor: "VaeImageProcessor", outp... class MimicMotionPipelineOutput (line 56) | class MimicMotionPipelineOutput(BaseOutput): class MimicMotionPipeline (line 69) | class MimicMotionPipeline(DiffusionPipeline): method __init__ (line 95) | def __init__( method _encode_image (line 117) | def _encode_image( method _encode_pose_image (line 164) | def _encode_pose_image( method _encode_vae_image (line 182) | def _encode_vae_image( method _get_add_time_ids (line 205) | def _get_add_time_ids( method decode_latents (line 235) | def decode_latents( method check_inputs (line 268) | def check_inputs(self, image, height, width): method prepare_latents (line 282) | def prepare_latents( method guidance_scale (line 317) | def guidance_scale(self): method do_classifier_free_guidance (line 324) | def do_classifier_free_guidance(self): method num_timesteps (line 330) | def num_timesteps(self): method prepare_extra_step_kwargs (line 333) | def prepare_extra_step_kwargs(self, generator, eta): method __call__ (line 351) | def __call__( FILE: mimicmotion/utils/dift_utils.py class MyUNet2DConditionModel (line 13) | class MyUNet2DConditionModel(UNet2DConditionModel): method forward (line 14) | def forward( class OneStepSDPipeline (line 165) | class OneStepSDPipeline(StableDiffusionPipeline): method __call__ (line 167) | def __call__( class SDFeaturizer (line 185) | class SDFeaturizer: method __init__ (line 186) | def __init__(self, sd_id='pretrained_models/stable-diffusion-v1-4', we... method forward (line 204) | def forward(self, class DIFT_Demo (line 250) | class DIFT_Demo: method __init__ (line 251) | def __init__(self, source_img, source_dift, source_img_size): method query (line 257) | def query(self, target_img, target_dift, target_img_size, query_point,... FILE: mimicmotion/utils/flow_utils.py class ForwardWarp (line 11) | class ForwardWarp(nn.Module): method __init__ (line 14) | def __init__( method forward (line 19) | def forward(self, img, flo): method get_gaussian_weights (line 67) | def get_gaussian_weights(self, x, y, x1, x2, y1, y2): method sample_one (line 75) | def sample_one(self, img, shiftx, shifty, weight): function get_edge (line 156) | def get_edge(data, blur=False): function get_max (line 167) | def get_max(score, bbox): function nms (line 174) | def nms(score, ks): function image_flow_crop (line 181) | def image_flow_crop(img1, img2, flow, crop_size, phase): function image_crop (line 207) | def image_crop(img, crop_size): function image_flow_resize (line 219) | def image_flow_resize(img1, img2, flow, short_size=None, long_size=None): function image_resize (line 242) | def image_resize(img, short_size=None, long_size=None): function image_pose_crop (line 263) | def image_pose_crop(img, posemap, crop_size, scale): function neighbor_elim (line 273) | def neighbor_elim(ph, pw, d): function remove_border (line 287) | def remove_border(mask): function flow_sampler (line 293) | def flow_sampler(flow, strategy=['grid'], bg_ratio=1./6400, nms_ks=15, m... function image_flow_aug (line 372) | def image_flow_aug(img1, img2, flow, flip_horizon=True): function flow_aug (line 381) | def flow_aug(flow, reverse=True, scale=True, rotate=True): function draw_gaussian (line 396) | def draw_gaussian(img, pt, sigma, type='Gaussian'): FILE: mimicmotion/utils/geglu_patch.py function patch_geglu_inplace (line 4) | def patch_geglu_inplace(): FILE: mimicmotion/utils/loader.py class MimicMotionModel (line 18) | class MimicMotionModel(torch.nn.Module): method __init__ (line 19) | def __init__(self, base_model_path): function create_ctrl_pipeline (line 38) | def create_ctrl_pipeline(infer_config, device): function create_pipeline (line 60) | def create_pipeline(infer_config, device): FILE: mimicmotion/utils/utils.py function get_cmp_flow (line 16) | def get_cmp_flow(cmp, frames, sparse_optical_flow, mask): function sample_optical_flow (line 47) | def sample_optical_flow(A, B, h, w): function get_sparse_flow (line 72) | def get_sparse_flow(poses, h, w, t): function sample_inputs_flow (line 87) | def sample_inputs_flow(first_frame, poses, poses_subset): function pose2track (line 115) | def pose2track(points_list, height, width): function pose2track_batch (line 132) | def pose2track_batch(points_list, height, width, batch_size): function points_to_flows_batch (line 150) | def points_to_flows_batch(points_list, model_length, height, width, batc... function points_to_flows (line 173) | def points_to_flows(points_list, model_length, height, width): function interpolate_trajectory (line 196) | def interpolate_trajectory(points, n_points): function bivariate_Gaussian (line 214) | def bivariate_Gaussian(kernel_size, sig_x, sig_y, theta, grid=None, isot... function mesh_grid (line 238) | def mesh_grid(kernel_size): function pdf2 (line 254) | def pdf2(sigma_matrix, grid): function sigma_matrix2 (line 268) | def sigma_matrix2(sig_x, sig_y, theta): function save_to_mp4 (line 282) | def save_to_mp4(frames, save_path, fps=7): function read_frames (line 287) | def read_frames(video_path): function get_fps (line 303) | def get_fps(video_path): function save_videos_from_pil (line 311) | def save_videos_from_pil(pil_images, path, fps=8): FILE: mimicmotion/utils/visualizer.py function read_video_from_path (line 19) | def read_video_from_path(path): function draw_circle (line 31) | def draw_circle(rgb, coord, radius, color=(255, 0, 0), visible=True): function draw_line (line 46) | def draw_line(rgb, coord_y, coord_x, color, linewidth): function add_weighted (line 56) | def add_weighted(rgb, alpha, original, beta, gamma): class Visualizer (line 60) | class Visualizer: method __init__ (line 61) | def __init__( method visualize (line 85) | def visualize( method save_video (line 131) | def save_video(self, video, filename, writer=None, step=0): method draw_tracks_on_video (line 158) | def draw_tracks_on_video( method _draw_pred_tracks (line 280) | def _draw_pred_tracks( method _draw_gt_tracks (line 311) | def _draw_gt_tracks( function vis_flow_to_video (line 355) | def vis_flow_to_video(optical_flow, num_frames): function flow_to_image (line 369) | def flow_to_image(flow): function compute_color (line 407) | def compute_color(u, v): function make_color_wheel (line 451) | def make_color_wheel():