MCPcopy Create free account

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

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

↓ 5 callersMethodnormalize
Normalize an image array to [-1,1].
src/diffusers/image_processor.py:151
↓ 5 callersMethodnumpy_to_pt
Convert a NumPy image to a PyTorch tensor.
src/diffusers/pipelines/marigold/marigold_image_processing.py:59
↓ 5 callersMethodpost_process_latents
(self, prior_latents)
src/diffusers/models/transformers/prior_transformer.py:378
↓ 5 callersMethodprepare_init_args_and_inputs_for_common
(self)
tests/models/unets/test_models_unet_3d_condition.py:60
↓ 5 callersMethodpreprocess_video
r""" Preprocesses input video(s). Args: video (`List[PIL.Image]`, `List[List[PIL.Image]]`, `torch.Tensor`, `np.array`, `L
src/diffusers/video_processor.py:28
↓ 5 callersMethodpt_to_numpy
Convert a PyTorch tensor to a NumPy image.
src/diffusers/image_processor.py:143
↓ 5 callersMethodpt_to_numpy
Convert a PyTorch tensor to a NumPy image.
src/diffusers/pipelines/marigold/marigold_image_processing.py:51
↓ 5 callersFunctionrearrange_dims
(tensor: torch.Tensor)
src/diffusers/models/resnet.py:377
↓ 5 callersMethodresize_antialias
( image: torch.Tensor, size: Tuple[int, int], mode: str, is_aa: Optional[bool] = None )
src/diffusers/pipelines/marigold/marigold_image_processing.py:74
↓ 5 callersMethodset_image_to_text_mode
r"""Manually set the generation mode to image-conditioned text generation.
src/diffusers/pipelines/unidiffuser/pipeline_unidiffuser.py:260
↓ 5 callersMethodset_text_to_image_mode
r"""Manually set the generation mode to text-conditioned image generation.
src/diffusers/pipelines/unidiffuser/pipeline_unidiffuser.py:256
↓ 5 callersFunctionshave_segments
Removes segments. Positive values shave the first segments, negative shave the last segments.
src/diffusers/pipelines/stable_diffusion/convert_from_ckpt.py:69
↓ 5 callersMethodsimulate_backprop
(self, unet)
tests/others/test_ema.py:54
↓ 5 callersFunctionto_np
(tensor)
tests/pipelines/animatediff/test_animatediff_sdxl.py:28
↓ 5 callersFunctionupdate_unet_attention_ldm_to_diffusers
(ldm_keys, new_checkpoint, checkpoint, mapping)
src/diffusers/loaders/single_file_utils.py:724
↓ 5 callersFunctionupdate_unet_resnet_ldm_to_diffusers
(ldm_keys, new_checkpoint, checkpoint, mapping=None)
src/diffusers/loaders/single_file_utils.py:709
↓ 5 callersFunctionzero_module
(module)
src/diffusers/models/controlnet.py:869
↓ 4 callersMethod__init__
( self, in_channels: int, out_channels: int, prev_output_channel: int,
src/diffusers/pipelines/audioldm2/modeling_audioldm2.py:1357
↓ 4 callersMethod__init__
(self, c, c_skip=0, kernel_size=3, dropout=0.0)
src/diffusers/pipelines/wuerstchen/modeling_wuerstchen_common.py:29
↓ 4 callersMethod__init__
( self, dim: int, dim_out: Optional[int] = None, mult: int = 4, dropou
src/diffusers/models/attention.py:622
↓ 4 callersMethod__init__
( self, in_features: int, out_features: int, rank: int = 4, network_al
src/diffusers/models/lora.py:196
↓ 4 callersMethod__init__
( self, channels, num_res_blocks: int, hidden_size, hidden_dropout,
src/diffusers/models/unets/uvit_2d.py:308
↓ 4 callersMethod_apply_free_init
( self, latents: torch.Tensor, free_init_iteration: int, num_inference_steps:
src/diffusers/pipelines/free_init_utils.py:138
↓ 4 callersMethod_combine
r""" Combines a latent iamge img_vae of shape (B, C, H, W) and a CLIP-embedded image img_clip of shape (B, 1, clip_img_dim) into a sin
src/diffusers/pipelines/unidiffuser/pipeline_unidiffuser.py:790
↓ 4 callersMethod_get_init_keys
(input_class)
src/diffusers/configuration_utils.py:457
↓ 4 callersMethod_get_signature_keys
(cls, obj)
src/diffusers/models/modeling_utils.py:967
↓ 4 callersFunctionadd_noise_common
( state: CommonSchedulerState, original_samples: jnp.ndarray, noise: jnp.ndarray, timesteps: jnp.ndarray )
src/diffusers/schedulers/scheduling_utils_flax.py:282
↓ 4 callersMethodcheck_device_map_is_respected
(self, model, device_map)
tests/models/test_modeling_common.py:216
↓ 4 callersMethodcheck_latents_shape
(self, latents_name, latents, expected_shape)
src/diffusers/pipelines/unidiffuser/pipeline_unidiffuser.py:951
↓ 4 callersMethodcheck_over_configs
(self, time_step=0, **config)
tests/schedulers/test_scheduler_flax.py:646
↓ 4 callersFunctionconvert_state_dict
r""" Simply iterates over the state dict and replaces the patterns in `mapping` with the corresponding values. Args: state_dict (`dic
src/diffusers/utils/state_dict_utils.py:141
↓ 4 callersFunctioncosine_distance
(image_embeds, text_embeds)
src/diffusers/pipelines/stable_diffusion_safe/safety_checker.py:25
↓ 4 callersFunctioncosine_distance
(image_embeds, text_embeds)
src/diffusers/pipelines/stable_diffusion/safety_checker.py:26
↓ 4 callersFunctioncreate_dummy_object
Create the code for the dummy object corresponding to `name`.
utils/check_dummies.py:105
↓ 4 callersMethodcrop
(self, im, new_width, new_height)
src/diffusers/pipelines/stable_diffusion_gligen/pipeline_stable_diffusion_gligen.py:514
↓ 4 callersMethodenable_sequential_cpu_offload
r""" Offloads all models to CPU using accelerate, significantly reducing memory usage. When called, unet, text_encoder, vae and safety
src/diffusers/pipelines/kandinsky2_2/pipeline_kandinsky2_2_combined.py:182
↓ 4 callersMethodenable_sequential_cpu_offload
r""" Offloads all models (`unet`, `text_encoder`, `vae`, and `safety checker` state dicts) to CPU using 🤗 Accelerate, significantly re
src/diffusers/pipelines/kandinsky/pipeline_kandinsky_combined.py:196
↓ 4 callersMethodenable_vae_tiling
r""" Enable tiled VAE decoding. When this option is enabled, the VAE will split the input tensor into tiles to compute decoding and en
src/diffusers/pipelines/pipeline_utils.py:1902
↓ 4 callersMethodencode_prompt
r""" Encodes the prompt into text encoder hidden states. Args: prompt (`str` or `List[str]`, *optional*):
src/diffusers/pipelines/stable_diffusion_xl/pipeline_stable_diffusion_xl.py:277
↓ 4 callersMethodencode_prompt
r""" Encodes the prompt into text encoder hidden states. Args: prompt (`str` or `List[str]`, *optional*):
src/diffusers/pipelines/stable_diffusion_xl/pipeline_stable_diffusion_xl_img2img.py:298
↓ 4 callersMethodevent_type_range
Return [min_id, max_id] for an event type.
src/diffusers/pipelines/deprecated/spectrogram_diffusion/midi_utils.py:200
↓ 4 callersMethodextract_init_dict
(cls, config_dict, **kwargs)
src/diffusers/configuration_utils.py:461
↓ 4 callersFunctionfetch_diffusers_config
(checkpoint)
src/diffusers/loaders/single_file_utils.py:465
↓ 4 callersFunctionfind_backend
Find one (or multiple) backend in a code line of the init.
utils/check_dummies.py:58
↓ 4 callersFunctionfind_backend
Find one (or multiple) backend in a code line of the init.
utils/check_inits.py:50
↓ 4 callersMethodfull_loop
(self, **config)
tests/schedulers/test_scheduler_pndm.py:93
↓ 4 callersMethodfull_loop
(self, scheduler=None, **config)
tests/schedulers/test_scheduler_edm_dpmsolver_multistep.py:99
↓ 4 callersMethodfull_loop
(self, **config)
tests/schedulers/test_scheduler_ddim.py:24
↓ 4 callersMethodfull_loop
(self, **config)
tests/schedulers/test_scheduler_ddim_parallel.py:38
↓ 4 callersMethodfull_loop
(self, **config)
tests/schedulers/test_scheduler_euler.py:52
↓ 4 callersMethodfull_loop
(self, **config)
tests/schedulers/test_scheduler_ddim_inverse.py:24
↓ 4 callersMethodgelu
(self, gate: torch.Tensor)
src/diffusers/models/activations.py:81
↓ 4 callersMethodgenerate_language_model
Generates a sequence of hidden-states from the language model, conditioned on the embedding inputs. Parameters: inputs_
src/diffusers/pipelines/audioldm2/pipeline_audioldm2.py:265
↓ 4 callersFunctionget_asym_autoencoder_kl_config
(block_out_channels=None, norm_num_groups=None)
tests/models/autoencoders/test_models_vae.py:70
↓ 4 callersFunctionget_autoencoder_kl_config
(block_out_channels=None, norm_num_groups=None)
tests/models/autoencoders/test_models_vae.py:55
↓ 4 callersFunctionget_autoencoder_tiny_config
(block_out_channels=None)
tests/models/autoencoders/test_models_vae.py:91
↓ 4 callersFunctionget_consistency_vae_config
(block_out_channels=None, norm_num_groups=None)
tests/models/autoencoders/test_models_vae.py:104
↓ 4 callersMethodget_dummy_components
(self, adapter_type="full_adapter_xl", time_cond_proj_dim=None)
tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_adapter.py:60
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/unclip/test_unclip_image_variation.py:190
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/hunyuan_dit/test_hunyuan_dit.py:54
↓ 4 callersMethodget_dummy_components
(self, time_cond_proj_dim=None)
tests/pipelines/stable_diffusion_adapter/test_stable_diffusion_adapter.py:389
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/stable_diffusion_2/test_stable_diffusion_diffedit.py:63
↓ 4 callersMethodget_dummy_components
(self, class_cond=False)
tests/pipelines/consistency_models/test_consistency_models.py:63
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/latent_consistency_models/test_latent_consistency_models.py:38
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/latent_consistency_models/test_latent_consistency_models_img2img.py:46
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky2_2/test_kandinsky_combined.py:184
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky2_2/test_kandinsky_combined.py:305
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/stable_cascade/test_stable_cascade_decoder.py:135
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky/test_kandinsky_inpaint.py:223
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky/test_kandinsky.py:207
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky/test_kandinsky_img2img.py:229
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky/test_kandinsky_combined.py:163
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/kandinsky/test_kandinsky_combined.py:272
↓ 4 callersMethodget_dummy_components
(self)
tests/pipelines/wuerstchen/test_wuerstchen_combined.py:129
↓ 4 callersMethodget_dummy_components
(self, time_cond_proj_dim=None)
tests/pipelines/controlnet_xs/test_controlnetxs.py:141
↓ 4 callersMethodget_dummy_components_with_full_downscaling
Get dummy components with x8 VAE downscaling and 4 UNet down blocks. These dummy components are intended to fully-exercise the T2I-Adapter
tests/pipelines/stable_diffusion_adapter/test_stable_diffusion_adapter.py:144
↓ 4 callersMethodget_dummy_controlnet_from_unet
For some tests we also need the underlying ControlNetXS-Adapter. For these, we'll build the UNetControlNetXSModel from the UNet and ControlNetXS-Adapt
tests/models/unets/test_models_unet_controlnetxs.py:102
↓ 4 callersMethodget_dummy_inputs
(self, device, height=64, width=64, seed=0)
tests/pipelines/stable_diffusion_adapter/test_stable_diffusion_adapter.py:395
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/unidiffuser/test_unidiffuser.py:147
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/consistency_models/test_consistency_models.py:83
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/latent_consistency_models/test_latent_consistency_models.py:97
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/latent_consistency_models/test_latent_consistency_models_img2img.py:105
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet_img2img.py:292
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet_sdxl.py:606
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet_inpaint.py:347
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/controlnet/test_controlnet.py:605
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/deepfloyd_if/test_if.py:43
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_cascade/test_stable_cascade_prior.py:158
↓ 4 callersMethodget_dummy_inputs
(self, device, seed=0)
tests/pipelines/stable_diffusion_ldm3d/test_stable_diffusion_ldm3d.py:100
↓ 4 callersFunctionget_indent
Returns the indent in given line (as string).
utils/custom_init_isort.py:59
↓ 4 callersMethodget_inputs
(self, device, generator_device="cpu", dtype=torch.float32, seed=0)
tests/single_file/test_stable_diffusion_single_file.py:44
↓ 4 callersMethodget_inputs
(self, device="cpu", dtype=torch.float32, seed=0)
tests/pipelines/stable_diffusion_2/test_stable_diffusion_depth.py:534
↓ 4 callersMethodget_inputs
(self, device, seed=0, generate_latents=False)
tests/pipelines/unidiffuser/test_unidiffuser.py:593
↓ 4 callersMethodget_inputs
(self, seed=0, get_fixed_latents=False, device="cpu", dtype=torch.float32, shape=(1, 3, 64, 64))
tests/pipelines/consistency_models/test_consistency_models.py:183
↓ 4 callersMethodget_inputs
(self, seed=0)
tests/pipelines/stable_diffusion_panorama/test_stable_diffusion_panorama.py:275
↓ 4 callersMethodget_inputs
(self, device, generator_device="cpu", dtype=torch.float32, seed=0)
tests/pipelines/stable_diffusion/test_stable_diffusion_img2img.py:671
↓ 4 callersMethodget_inputs
(self, device, generator_device="cpu", dtype=torch.float32, seed=0)
tests/pipelines/stable_diffusion/test_stable_diffusion_inpaint.py:1024
↓ 4 callersFunctionget_module_dependencies
Refines the result of `extract_imports` to remove subfolders and get a proper list of module filenames: if a file as an import `from utils im
utils/tests_fetcher.py:560
↓ 4 callersMethodget_scheduler_config
(self, **kwargs)
tests/schedulers/test_scheduler_dpm_sde.py:14
↓ 4 callersMethodget_scheduler_config
(self, **kwargs)
tests/schedulers/test_scheduler_kdpm2_discrete.py:13
← previousnext →401–500 of 8,312, ranked by callers