MCPcopy Create free account

hub / github.com/Chen-Yang-Liu/Text2Earth / functions

Functions8,312 in github.com/Chen-Yang-Liu/Text2Earth

↓ 23 callersMethodfrom_pretrained
r""" Instantiate a pretrained MultiControlNet model from multiple pre-trained controlnet models. The model is set in evaluation mode
src/diffusers/pipelines/controlnet/multicontrolnet.py:114
↓ 23 callersMethodget_input_embeddings
(self)
src/diffusers/pipelines/blip_diffusion/modeling_blip2.py:421
↓ 23 callersMethodset_attn_processor
r""" Sets the attention processor to use to compute attention. Parameters: processor (`dict` of `AttentionProcessor` or o
src/diffusers/models/unets/uvit_2d.py:241
↓ 22 callersFunctionassert_mean_pixel_difference
(image, expected_image, expected_max_diff=10)
tests/pipelines/test_pipelines_common.py:2109
↓ 22 callersMethoddownload
r""" Download and cache a PyTorch diffusion pipeline from pretrained pipeline weights. Parameters: pretrained_model_name
src/diffusers/pipelines/pipeline_utils.py:1183
↓ 22 callersFunctiondownload_single_file_checkpoint
(repo_id, filename, tmpdir)
tests/single_file/single_file_testing_utils.py:15
↓ 22 callersMethodget_dummy_components
(self, time_cond_proj_dim=None)
tests/pipelines/stable_diffusion/test_stable_diffusion.py:127
↓ 22 callersMethodload_textual_inversion
r""" Load Textual Inversion embeddings into the text encoder of [`StableDiffusionPipeline`] (both 🤗 Diffusers and Automatic1111 format
src/diffusers/loaders/textual_inversion.py:267
↓ 21 callersMethoddecode
(self, latents, deterministic: bool = True, return_dict: bool = True)
src/diffusers/models/vae_flax.py:849
↓ 21 callersMethodget_dummy_inputs
( self, for_image_to_image=False, for_inpainting=False, for_sdxl=False, for_masks=False, for_instant_s
tests/pipelines/ip_adapters/test_ip_adapter_stable_diffusion.py:75
↓ 21 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_inpaint.py:172
↓ 21 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_video_diffusion/test_stable_video_diffusion.py:125
↓ 21 callersFunctionis_invisible_watermark_available
()
src/diffusers/utils/import_utils.py:422
↓ 21 callersMethodload_ip_adapter
Parameters: pretrained_model_name_or_path_or_dict (`str` or `List[str]` or `os.PathLike` or `List[os.PathLike]` or `dict` or `Lis
src/diffusers/loaders/ip_adapter.py:55
↓ 21 callersMethodpil_to_numpy
Convert a PIL image or a list of PIL images to NumPy arrays.
src/diffusers/image_processor.py:120
↓ 20 callersFunctionis_onnx_available
()
src/diffusers/utils/import_utils.py:366
↓ 20 callersMethodtest_output
(self)
tests/models/unets/test_unet_2d_blocks.py:208
↓ 19 callersMethodadd_noise
( self, original_samples: torch.Tensor, noise: torch.Tensor, timesteps: torch.
src/diffusers/schedulers/scheduling_lcm.py:595
↓ 19 callersMethodbatch_to_head_dim
r""" Reshape the tensor from `[batch_size, seq_len, dim]` to `[batch_size // heads, seq_len, dim * heads]`. `heads` is the number of h
src/diffusers/models/attention_processor.py:557
↓ 19 callersMethodinputs_dict
(self, seed=None)
tests/models/autoencoders/test_models_vae.py:363
↓ 19 callersFunctionto_np
(tensor)
tests/pipelines/stable_video_diffusion/test_stable_video_diffusion.py:39
↓ 18 callersMethod_sigma_to_alpha_sigma_t
(self, sigma)
src/diffusers/schedulers/scheduling_sasolver.py:366
↓ 18 callersMethodget_dummy_inputs_by_type
(self, device, seed=0, input_image_type="pt", output_type="np")
tests/pipelines/test_pipelines_common.py:487
↓ 18 callersMethodget_inputs
(self, device, generator_device="cpu", dtype=torch.float32, seed=0)
tests/pipelines/stable_diffusion/test_stable_diffusion.py:851
↓ 18 callersFunctionis_compiled_module
Check whether the module was compiled with torch.compile()
src/diffusers/utils/torch_utils.py:86
↓ 18 callersMethodset_ip_adapter_scale
Set IP-Adapter scales per-transformer block. Input `scale` could be a single config or a list of configs for granular control over ea
src/diffusers/loaders/ip_adapter.py:248
↓ 17 callersMethodcheck_over_forward
(self, time_step=0, **forward_kwargs)
tests/schedulers/test_schedulers.py:431
↓ 17 callersMethodget_dummy_components
(self, skip_first_text_encoder=False, time_cond_proj_dim=None)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_inpaint.py:75
↓ 17 callersMethodget_dummy_components
(self, time_cond_proj_dim=None)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl.py:79
↓ 17 callersMethodset_begin_index
Sets the begin index for the scheduler. This function should be run from pipeline before the inference. Args: begin_inde
src/diffusers/schedulers/scheduling_lcm.py:289
↓ 17 callersMethodstep_plms
Predict the sample from the previous timestep by reversing the SDE. This function propagates the sample with the linear multistep met
src/diffusers/schedulers/scheduling_pndm.py:319
↓ 17 callersMethodstep_prk
Predict the sample from the previous timestep by reversing the SDE. This function propagates the sample with the Runge-Kutta method.
src/diffusers/schedulers/scheduling_pndm.py:259
↓ 16 callersMethod__init__
(self, in_channels: int, out_channels: int, mid_channels: Optional[int] = None)
src/diffusers/models/unets/unet_1d_blocks.py:562
↓ 16 callersMethod__init__
( self, in_channels: int, prev_output_channel: int, out_channels: int,
src/diffusers/models/unets/unet_3d_blocks.py:833
↓ 16 callersMethod_load_ip_adapter_weights
(self, state_dicts, low_cpu_mem_usage=False)
src/diffusers/loaders/unet.py:1017
↓ 16 callersMethodfuse_lora
r""" Fuses the LoRA parameters into the original parameters of the corresponding blocks. <Tip warning={true}> This is an exp
src/diffusers/loaders/lora.py:745
↓ 16 callersMethodget_attention_scores
r""" Compute the attention scores. Args: query (`torch.Tensor`): The query tensor. key (`torch.Tensor`): The
src/diffusers/models/attention_processor.py:601
↓ 16 callersMethodget_dummy_input
( self, include_temb=True, include_res_hidden_states_tuple=False, include_enco
tests/models/unets/test_unet_blocks_common.py:46
↓ 16 callersMethodget_image_encoder
(self, repo_id, subfolder)
tests/pipelines/ip_adapters/test_ip_adapter_stable_diffusion.py:65
↓ 16 callersMethodget_processor
r""" Get the attention processor in use. Args: return_deprecated_lora (`bool`, *optional*, defaults to `False`):
src/diffusers/models/attention_processor.py:424
↓ 16 callersFunctionget_timestep_embedding
This matches the implementation in Denoising Diffusion Probabilistic Models: Create sinusoidal timestep embeddings. :param timesteps: a 1-D
src/diffusers/models/embeddings.py:27
↓ 16 callersFunctionis_bs4_available
()
src/diffusers/utils/import_utils.py:414
↓ 16 callersFunctionis_ftfy_available
()
src/diffusers/utils/import_utils.py:410
↓ 16 callersFunctionis_transformers_version
Args: Compares the current Transformers version to a given reference with an operation. operation (`str`): A string repre
src/diffusers/utils/import_utils.py:679
↓ 16 callersFunctionmake_zero_conv
(in_channels, out_channels=None)
src/diffusers/models/controlnet_xs.py:1897
↓ 15 callersFunction_get_task_class
(mapping, pipeline_class_name, throw_error_if_not_exist: bool = True)
src/diffusers/pipelines/auto_pipeline.py:152
↓ 15 callersMethod_sigma_to_alpha_sigma_t
(self, sigma)
src/diffusers/schedulers/scheduling_dpmsolver_multistep_inverse.py:356
↓ 15 callersMethod_sigma_to_alpha_sigma_t
(self, sigma)
src/diffusers/schedulers/scheduling_dpmsolver_multistep.py:468
↓ 15 callersMethod_test_save_load_optional_components
(self)
tests/pipelines/deepfloyd_if/__init__.py:152
↓ 15 callersMethodenable_xformers_memory_efficient_attention
r""" Enable memory efficient attention from [xFormers](https://facebookresearch.github.io/xformers/). When this option is enabled, yo
src/diffusers/models/modeling_utils.py:224
↓ 15 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_img2img.py:184
↓ 14 callersMethod_modify_inputs_for_ip_adapter_test
(self, inputs: Dict[str, Any])
tests/pipelines/test_pipelines_common.py:253
↓ 14 callersMethod_sigma_to_alpha_sigma_t
(self, sigma)
src/diffusers/schedulers/scheduling_dpmsolver_singlestep.py:422
↓ 14 callersMethodcheck_over_configs
(self, time_step=0, **config)
tests/schedulers/test_scheduler_dpm_multi.py:41
↓ 14 callersMethodencode_prompt
( self, tokenizers, text_encoders, prompt: str, num_images_per_prompt: int = 1, negative_prompt: str =
tests/pipelines/test_pipelines_common.py:1966
↓ 14 callersMethodget_dummy_components
(self)
tests/pipelines/stable_video_diffusion/test_stable_video_diffusion.py:59
↓ 14 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_diffusion_2/test_stable_diffusion_depth.py:163
↓ 14 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet_sdxl.py:166
↓ 14 callersMethodget_dummy_inputs
(self, device, seed=0, img_res=64, output_pil=True)
tests/pipelines/stable_diffusion/test_stable_diffusion_inpaint.py:169
↓ 14 callersMethodget_generator
(self, device, seed=0)
tests/pipelines/text_to_video_synthesis/test_text_to_video_zero_sdxl.py:153
↓ 14 callersFunctionis_peft_available
()
src/diffusers/utils/import_utils.py:426
↓ 14 callersFunctionis_safetensors_compatible
Checking for safetensors compatibility: - By default, all models are saved with the default pytorch serialization, so we use the list of defa
src/diffusers/pipelines/pipeline_loading_utils.py:92
↓ 14 callersMethodset_attn_processor
r""" Sets the attention processor to use to compute attention. Parameters: processor (`dict` of `AttentionProcessor` or o
src/diffusers/pipelines/wuerstchen/modeling_wuerstchen_prior.py:91
↓ 13 callersFunction_get_library_root_logger
()
src/diffusers/utils/logging.py:73
↓ 13 callersMethod_get_signature_keys
(cls, obj)
src/diffusers/pipelines/pipeline_utils.py:1555
↓ 13 callersFunctionassign_to_checkpoint
This does the final conversion step: take locally converted weights and apply a global renaming to them. It splits attention layers, and take
src/diffusers/pipelines/stable_diffusion/convert_from_ckpt.py:168
↓ 13 callersMethoddevice
r""" Returns: `torch.device`: The torch device on which the pipeline is located.
src/diffusers/pipelines/pipeline_utils.py:449
↓ 13 callersMethodfull_loop
(self, scheduler=None, **config)
tests/schedulers/test_scheduler_unipc.py:91
↓ 13 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/text_to_video_synthesis/test_text_to_video_zero_sdxl.py:135
↓ 13 callersMethodget_scheduler_config
(self)
tests/schedulers/test_schedulers.py:355
↓ 13 callersMethodsort
(a, b)
src/diffusers/schedulers/scheduling_dpmsolver_sde.py:44
↓ 12 callersFunction_get_model_file
( pretrained_model_name_or_path: Union[str, Path], *, weights_name: str, subfolder: Optional[s
src/diffusers/utils/hub_utils.py:281
↓ 12 callersMethod_maybe_convert_prompt
r""" Maybe convert a prompt into a "multi vector"-compatible prompt. If the prompt includes a token that corresponds to a multi-vector
src/diffusers/loaders/textual_inversion.py:145
↓ 12 callersMethodapply_watermark
(self, images: List[PIL.Image.Image], sample_size=None)
src/diffusers/pipelines/deepfloyd_if/watermark.py:19
↓ 12 callersMethodcheck_over_configs
(self, time_step=0, **config)
tests/schedulers/test_scheduler_dpm_multi_inverse.py:34
↓ 12 callersMethodget_dummy_components
(self, skip_first_text_encoder=False, time_cond_proj_dim=None)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_img2img.py:76
↓ 12 callersMethodget_dummy_inputs_with_latents
(self, device, seed=0)
tests/pipelines/unidiffuser/test_unidiffuser.py:181
↓ 12 callersFunctionis_note_seq_available
()
src/diffusers/utils/import_utils.py:394
↓ 11 callersMethod__init__
( self, in_channels: int, prev_output_channel: int, out_channels: int,
src/diffusers/pipelines/deprecated/versatile_diffusion/modeling_text_unet.py:1789
↓ 11 callersMethod_sigma_to_alpha_sigma_t
(self, sigma)
src/diffusers/schedulers/scheduling_deis_multistep.py:337
↓ 11 callersMethod_test_inference_batch_consistent
( self, batch_sizes=[2], additional_params_copy_to_batched_inputs=["num_inference_steps"], batch_gener
tests/pipelines/test_pipelines_common.py:1032
↓ 11 callersMethod_test_marigold_depth
( self, generator_seed: int = 0, expected_slice: np.ndarray = None, atol: floa
tests/pipelines/marigold/test_marigold_depth.py:142
↓ 11 callersMethod_test_marigold_normals
( self, generator_seed: int = 0, expected_slice: np.ndarray = None, atol: floa
tests/pipelines/marigold/test_marigold_normals.py:142
↓ 11 callersMethodcheck_over_configs
(self, time_step=0, **config)
tests/schedulers/test_scheduler_dpm_single.py:39
↓ 11 callersMethoddownsample
Downsamples the provided mask tensor to match the expected dimensions for scaled dot-product attention. If the aspect ratio of the ma
src/diffusers/image_processor.py:970
↓ 11 callersMethodencode
(self, sample, deterministic: bool = True, return_dict: bool = True)
src/diffusers/models/vae_flax.py:837
↓ 11 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet_sdxl_img2img.py:154
↓ 11 callersMethodget_encoder_hidden_states
(self, seed=0, shape=(4, 77, 768), fp16=False)
tests/models/unets/test_models_unet_2d_condition.py:1226
↓ 11 callersMethodget_latents
(self, seed=0, shape=(4, 4, 64, 64), fp16=False)
tests/models/unets/test_models_unet_2d_condition.py:1128
↓ 11 callersMethodget_scheduler_config
(self, **kwargs)
tests/schedulers/test_scheduler_lcm.py:16
↓ 11 callersMethodget_unet_model
(self, fp16=False, model_id="CompVis/stable-diffusion-v1-4")
tests/models/unets/test_models_unet_2d_condition.py:1133
↓ 11 callersMethodpostprocess_video
r""" Converts a video tensor to a list of frames for export. Args: video (`torch.Tensor`): The video as a tensor.
src/diffusers/video_processor.py:89
↓ 11 callersMethodprogress_bar
(self, iterable=None, total=None)
src/diffusers/pipelines/kandinsky2_2/pipeline_kandinsky2_2_combined.py:193
↓ 11 callersMethodset_attention_slice
r""" Enable sliced attention computation. When this option is enabled, the attention module splits the input tensor in slices to comp
src/diffusers/models/controlnet.py:597
↓ 11 callersMethodto_np
(self, image)
tests/others/test_image_processor.py:48
↓ 10 callersMethod__init__
( self, query_dim: int, cross_attention_dim: Optional[int] = None, heads: int
src/diffusers/models/attention_processor.py:94
↓ 10 callersMethodcheck_over_configs
(self, time_step=0, **config)
tests/schedulers/test_scheduler_flax.py:384
↓ 10 callersMethodfrom_unet
r""" Instantiate a [`ControlNetModel`] from [`UNet2DConditionModel`]. Parameters: unet (`UNet2DConditionModel`):
src/diffusers/models/controlnet.py:445
↓ 10 callersMethodget_dummy_components
(self)
tests/pipelines/unidiffuser/test_unidiffuser.py:89
↓ 10 callersMethodget_dummy_inputs
(self, seed=0)
tests/pipelines/stable_diffusion/test_onnx_stable_diffusion.py:42
← previousnext →101–200 of 8,312, ranked by callers