MCPcopy Create free account

hub / github.com/brycedrennan/imaginAIry / functions

Functions2,992 in github.com/brycedrennan/imaginAIry

↓ 1 callersMethod_momentum_update
(self)
imaginairy/vendored/blip/blip_pretrain.py:286
↓ 1 callersMethod_move_to_cpu
(self, key)
imaginairy/utils/model_cache.py:251
↓ 1 callersFunction_normalize_image_size
(resolution: str | int | tuple[int, int])
imaginairy/utils/named_resolutions.py:60
↓ 1 callersFunction_np_to_t
(img_np)
imaginairy/img_processors/densepose.py:166
↓ 1 callersMethod_p_sample_ddim_formula
( model, noisy_latent, noise_pred, e_t, sqrt_one_minus_at, a_t
imaginairy/samplers/ddim.py:190
↓ 1 callersMethod_post_structural_copy
(self: TAdapter, source: TAdapter)
imaginairy/vendored/refiners/fluxion/adapters/adapter.py:84
↓ 1 callersMethod_pre_structural_copy
(self)
imaginairy/vendored/refiners/fluxion/adapters/adapter.py:80
↓ 1 callersMethod_pretty_print_args
Flatten nested tuples and print tensors with their shape and other informations.
imaginairy/vendored/refiners/fluxion/layers/chain.py:216
↓ 1 callersFunction_process_nvidia_smi_output
(output)
imaginairy/utils/debug_info.py:67
↓ 1 callersMethod_resize
(self, mask, matrix, w, h)
imaginairy/img_processors/densepose.py:500
↓ 1 callersMethod_run_basic_layers_match_stage
Run the basic layers match stage of the conversion process.
imaginairy/vendored/refiners/fluxion/model_converter.py:355
↓ 1 callersMethod_run_init_stage
Run the init stage of the conversion process.
imaginairy/vendored/refiners/fluxion/model_converter.py:339
↓ 1 callersMethod_run_shape_and_layers_match_stage
Run the shape and layers match stage of the conversion process.
imaginairy/vendored/refiners/fluxion/model_converter.py:372
↓ 1 callersFunction_scandir
(dir_path, suffix, recursive)
imaginairy/vendored/facexlib/utils/misc.py:100
↓ 1 callersMethod_show_error_in_tree
(self, name: str, /, max_lines: int = 20)
imaginairy/vendored/refiners/fluxion/layers/chain.py:188
↓ 1 callersMethod_show_only_tag
Whether to show only the tag when printing the module. This is useful to distinguish between Chain subclasses that override their forward fro
imaginairy/vendored/refiners/fluxion/layers/module.py:90
↓ 1 callersMethod_sliced_attention
( self, query: Float[Tensor, "batch num_queries embedding_dim"], key: Float[Tensor, "b
imaginairy/vendored/refiners/fluxion/layers/attentions.py:69
↓ 1 callersFunction_traverse
(curr_data, curr_path)
imaginairy/utils/data_distorter.py:141
↓ 1 callersMethod_verify_basic_layers_count
Verify that the source and target models have the same number of basic layers.
imaginairy/vendored/refiners/fluxion/model_converter.py:456
↓ 1 callersMethod_verify_missing_basic_layers
Verify that the source and target models do not have missing basic layers.
imaginairy/vendored/refiners/fluxion/model_converter.py:499
↓ 1 callersFunctionadaptive_instance_normalization
Adaptive instance normalization. Adjust the reference features to have the similar color and illuminations as those in the degradate features
imaginairy/vendored/codeformer/codeformer_arch.py:30
↓ 1 callersMethodadd_embedding
(self, embedding: Tensor)
imaginairy/vendored/refiners/foundationals/clip/concepts.py:34
↓ 1 callersFunctionadd_hooks
(module, prefix="")
imaginairy/weight_management/execution_trace.py:22
↓ 1 callersFunctionadd_noise_interval
( scheduler: Scheduler, /, x: torch.Tensor, noise: torch.Tensor, initial_timestep: torch.T
imaginairy/vendored/refiners/foundationals/latent_diffusion/restart.py:14
↓ 1 callersFunctionadd_sliced_attention_to_scaled_dot_product_attention
Patch refiners ScaledDotProductAttention so that it uses sliced attention It reduces peak memory usage.
imaginairy/modules/refiners_sd.py:788
↓ 1 callersFunctionadd_tiles
(tiles, base_img, tile_coords, tile_size, overlap)
imaginairy/utils/feather_tile.py:110
↓ 1 callersFunctionadd_timed_methods_to_logger
Monkey patches the default python logger to have timed logs
imaginairy/utils/log_utils.py:78
↓ 1 callersMethodadd_token
(self, token: str, token_id: int)
imaginairy/vendored/refiners/foundationals/clip/concepts.py:58
↓ 1 callersFunctionaimg
🤖🧠 ImaginAIry. Pythonic generation of images via AI
imaginairy/cli/main.py:29
↓ 1 callersFunctionalign_crop_face_landmarks
Align and crop face with landmarks. The output_size and transform_size are based on width. The height is adjusted based on shrink_ratio_h/shr
imaginairy/vendored/facexlib/utils/face_utils.py:31
↓ 1 callersFunctionall_gather_with_grad
Performs all_gather operation on the provided tensors. Graph remains connected for backward grad computation.
imaginairy/vendored/blip/blip_retrieval.py:355
↓ 1 callersMethodanalyse
Analyze image and return some suggestions of crops (coordinates). This implementation / algorithm is really slow for large images.
imaginairy/vendored/smart_crop.py:77
↓ 1 callersFunctionapply_controlnet
(base_state_dict, controlnet_state_dict)
scripts/controlnet_convert.py:112
↓ 1 callersMethodapply_model
(self, *args, **kwargs)
imaginairy/samplers/kdiff.py:23
↓ 1 callersFunctionaspect_ratio
Calculate the aspect ratio of a given width and height. Args: width (int): The width dimension. height (int): The height dimension.
imaginairy/utils/img_utils.py:264
↓ 1 callersFunctionassert_tensor_uint8_255_bchw
(img)
imaginairy/img_processors/densepose.py:307
↓ 1 callersFunctionassess_memory_usage
()
scripts/asses_memory_usage.py:9
↓ 1 callersFunctionassociate_detections_to_trackers
Assigns detections to tracked object (both represented as bounding boxes) Returns: 3 lists of matches, unmatched_detections and unmatched
imaginairy/vendored/facexlib/tracking/data_association.py:29
↓ 1 callersMethodattention
(self, h_: torch.Tensor)
imaginairy/modules/sgm/diffusionmodules/model.py:233
↓ 1 callersFunctionavailable_models
Returns the names of available CLIP models.
imaginairy/vendored/clip/clip.py:109
↓ 1 callersFunctionavg_pool_nd
Create a 1D, 2D, or 3D average pooling module.
imaginairy/modules/diffusion/util.py:275
↓ 1 callersFunctionavg_pool_nd
Create a 1D, 2D, or 3D average pooling module.
imaginairy/modules/sgm/diffusionmodules/util.py:293
↓ 1 callersMethodbasic_attributes
Return a dictionary of basic attributes of the module. Basic attributes are public attributes made of basic types (int, float, str, bool) or
imaginairy/vendored/refiners/fluxion/layers/module.py:62
↓ 1 callersFunctionbasic_clean
(text)
imaginairy/vendored/clip/simple_tokenizer.py:58
↓ 1 callersFunctionbatched_decode
Decode locations from predictions using priors to undo the encoding we did for offset regression at train time. Args: b_loc (tensor):
imaginairy/vendored/facexlib/detection/retinaface_utils.py:297
↓ 1 callersFunctionbatched_decode_landm
Decode landm from predictions using priors to undo the encoding we did for offset regression at train time. Args: pre (tensor): landm
imaginairy/vendored/facexlib/detection/retinaface_utils.py:320
↓ 1 callersMethodbatched_transform
Arguments: frames: a list of PIL.Image, or torch.Tensor(shape=[n, h, w, c], type=np.float32, BGR format).
imaginairy/vendored/facexlib/detection/retinaface.py:261
↓ 1 callersFunctionblip_model
()
imaginairy/enhancers/describe_image_blip.py:23
↓ 1 callersMethodbpe
(self, token)
imaginairy/vendored/clip/simple_tokenizer.py:94
↓ 1 callersMethodbuild_attention_mask
(self)
imaginairy/vendored/clip/model.py:404
↓ 1 callersFunctionbuild_model
(state_dict: dict)
imaginairy/vendored/clip/model.py:480
↓ 1 callersMethodbyte_pair_encoding
(self, token: str)
imaginairy/vendored/refiners/foundationals/clip/tokenizer.py:73
↓ 1 callersFunctioncalc_and_save_compvis_traces
()
imaginairy/weight_management/execution_trace.py:214
↓ 1 callersFunctioncalc_and_save_sd15_diffusers_traces
()
imaginairy/weight_management/execution_trace.py:244
↓ 1 callersFunctioncalc_norm_sum_sq_diff
(img, img2)
tests/utils.py:22
↓ 1 callersMethodcalculate_adaptive_weight
( self, nll_loss: torch.Tensor, g_loss: torch.Tensor, last_layer: torch.Tensor )
imaginairy/modules/sgm/autoencoding/losses/discriminator_loss.py:201
↓ 1 callersFunctioncalculate_blurriness_level
(img)
imaginairy/enhancers/blur_detect.py:8
↓ 1 callersFunctioncalculate_points
(heatmaps)
imaginairy/vendored/facexlib/alignment/awing_arch.py:8
↓ 1 callersMethodcalculate_text_conditioning_kwargs
( self, positive_prompts: List[WeightedPrompt], negative_prompts: List[WeightedPrompt]
imaginairy/modules/refiners_sd.py:221
↓ 1 callersMethodcallback
(fut)
imaginairy/vendored/k_diffusion/gns.py:26
↓ 1 callersMethodcast_weights
(self, source_weights)
imaginairy/weight_management/conversion.py:74
↓ 1 callersFunctioncategory_list
Return the names of available phrase-lists.
imaginairy/enhancers/prompt_expansion.py:33
↓ 1 callersFunctioncheck_huggingface_url_authorized
(url: str)
imaginairy/utils/downloads.py:68
↓ 1 callersFunctioncheck_torch_version
Check that the torch version is compatible with ImaginAIry. https://github.com/brycedrennan/imaginAIry/issues/329
imaginairy/utils/__init__.py:267
↓ 1 callersFunctionchoose_huggingface_weights
Chooses the best weights file from a list of filenames Prefers safetensors format and fp16 dtype
imaginairy/utils/downloads.py:160
↓ 1 callersFunctionclip_mask_model
()
imaginairy/enhancers/clip_masking.py:21
↓ 1 callersFunctionclip_up_models
()
imaginairy/enhancers/upscale_riverwing.py:193
↓ 1 callersMethodcluster_size_ema_update
(self, new_cluster_size)
imaginairy/modules/sgm/autoencoding/regularizers/quantize.py:339
↓ 1 callersFunctioncodeformer_model
()
imaginairy/enhancers/face_restoration_codeformer.py:65
↓ 1 callersFunctioncolorize_img
Colorizes black and white images or re-colors existing images. Optionally adds a caption. Args: img (Image): The image to be coloriz
imaginairy/api/colorize.py:14
↓ 1 callersMethodcompare_models
Compare the outputs of the source and target models. - `source_args`: The arguments to pass to the source model it can be either a t
imaginairy/vendored/refiners/fluxion/model_converter.py:298
↓ 1 callersMethodcompute_relative_embedding
(self, x: Tensor)
imaginairy/vendored/refiners/foundationals/segment_anything/image_encoder.py:115
↓ 1 callersMethodcompute_sag_mask
( self, latents: Float[Tensor, "batch_size channels height width"], classifier_free_guidance: bool = T
imaginairy/vendored/refiners/foundationals/latent_diffusion/self_attention_guidance.py:76
↓ 1 callersMethodcompute_self_attention_guidance
( self, x: Tensor, noise: Tensor, step: int, *, clip_text_embedding: Tensor, **kwargs: Tensor )
imaginairy/vendored/refiners/foundationals/latent_diffusion/model.py:85
↓ 1 callersMethodcondition_encoder
(self)
imaginairy/vendored/refiners/foundationals/latent_diffusion/t2i_adapter.py:198
↓ 1 callersFunctionconditioning_to_img
(conditioning)
imaginairy/utils/log_utils.py:365
↓ 1 callersFunctionconv_1x1_bn
(inp, oup)
imaginairy/vendored/facexlib/matting/mobilenetv2.py:26
↓ 1 callersFunctionconv_bn
(inp, oup, stride)
imaginairy/vendored/facexlib/matting/mobilenetv2.py:22
↓ 1 callersFunctionconvert_realesrgan_state_dict
(state_dict)
imaginairy/vendored/realesrgan.py:358
↓ 1 callersMethodconvert_to_grid_features
(clip_image_encoder: CLIPImageEncoderH)
imaginairy/vendored/refiners/foundationals/latent_diffusion/image_prompt.py:444
↓ 1 callersFunctionconvert_weights
Convert applicable model parameters to fp16.
imaginairy/vendored/clip/model.py:451
↓ 1 callersMethodcopy_params
(self)
imaginairy/vendored/blip/blip_retrieval.py:272
↓ 1 callersMethodcopy_params
(self)
imaginairy/vendored/blip/blip_pretrain.py:277
↓ 1 callersFunctioncosine_distance
(embeds_a, embeds_b)
imaginairy/enhancers/describe_image_clip.py:67
↓ 1 callersFunctioncould_install_better_torch_version
()
imaginairy/utils/torch_installer.py:41
↓ 1 callersFunctioncreate_body_pose
(original_img_t)
imaginairy/img_processors/openpose.py:526
↓ 1 callersFunctioncreate_body_pose_img
(original_img_t)
imaginairy/img_processors/openpose.py:516
↓ 1 callersFunctioncreate_depth_map
( img: "Tensor", model_type="dpt_hybrid_384", max_size=512 )
imaginairy/img_processors/control_modes.py:42
↓ 1 callersFunctioncreate_hed_map
(img_t)
imaginairy/img_processors/hed_boundary.py:187
↓ 1 callersFunctioncreate_node_map
Create a map of node numbers to paths in a nested dictionary. Include all nodes, not just leaves. Example: data = {"a": {"b": ["c",
imaginairy/utils/data_distorter.py:116
↓ 1 callersFunctioncreate_surprise_me_images
( img, outdir, person=None, make_gif=True, width=None, height=None, seed=None )
imaginairy/utils/surprise_me.py:227
↓ 1 callersFunctioncreate_video
(image_dir, output_file, fps=60, frame_size=(640, 480), codec="MP4V")
docs/examples/immortal_pearl_earring.py:98
↓ 1 callersFunctioncreate_window_3d
(window_size, channel=1)
imaginairy/enhancers/video_interpolation/rife/msssim.py:28
↓ 1 callersFunctioncrop_pct
(img, roi_pcts)
tests/test_modules/test_autoencoders.py:91
↓ 1 callersMethodcrops
( self, image, crop_width, crop_height, max_scale=1, min_scale
imaginairy/vendored/smart_crop.py:191
↓ 1 callersFunctioncvt_tform_mat_for_cv2
Function: ---------- Convert Transform Matrix 'trans' into 'cv2_trans' which could be directly used by cv2.warpAffine():
imaginairy/vendored/facexlib/detection/matlab_cp2tform.py:170
↓ 1 callersFunctiondecode
Decode locations from predictions using priors to undo the encoding we did for offset regression at train time. Args: loc (tensor): lo
imaginairy/vendored/facexlib/detection/retinaface_utils.py:254
↓ 1 callersMethoddecode
(self, z: torch.Tensor, **kwargs)
imaginairy/modules/sgm/autoencoder.py:222
↓ 1 callersFunctiondecode_landm
Decode landm from predictions using priors to undo the encoding we did for offset regression at train time. Args: pre (tensor): landm
imaginairy/vendored/facexlib/detection/retinaface_utils.py:274
↓ 1 callersMethoddecode_latents
(self, x: Tensor)
imaginairy/vendored/refiners/foundationals/latent_diffusion/multi_diffusion.py:86
← previousnext →701–800 of 2,992, ranked by callers