MCPcopy Create free account

hub / github.com/KohakuBlueleaf/LyCORIS / functions

Functions372 in github.com/KohakuBlueleaf/LyCORIS

↓ 32 callersMethodapply_to
(self)
lycoris/modules/ia3.py:87
↓ 29 callersMethodstate_dict
(self, *args, destination=None, prefix="", keep_vars=False)
lycoris/modules/base.py:41
↓ 22 callersFunctionstr_bool
(val)
lycoris/utils/__init__.py:44
↓ 18 callersMethoddevice
(self)
lycoris/modules/base.py:281
↓ 17 callersFunctioncreate_lycoris
( module, multiplier=1.0, linear_dim=4, linear_alpha=1, warn_on_unmatched=True, **kwargs )
lycoris/wrapper.py:51
↓ 14 callersMethodload_state_dict
(self, state_dict, strict: bool = True, assign: bool = False)
lycoris/modules/dylora.py:81
↓ 14 callersMethodrestore
(self)
lycoris/wrapper.py:595
↓ 13 callersMethodapply_preset
(cls, preset)
lycoris/wrapper.py:207
↓ 12 callersFunctionfactorization
return a tuple of two value of input dimension decomposed by the number closest to factor second value is higher or equal than first value.
lycoris/functional/general.py:14
↓ 11 callersMethod_current_weight
(self)
lycoris/modules/base.py:292
↓ 11 callersFunctionmatch
(match_list, regex_text)
lycoris/utils/__init__.py:373
↓ 10 callersMethodmerge_to
(self, weight=1.0, *, precise: bool = False)
lycoris/wrapper.py:599
↓ 10 callersMethodnamed_modules
(self, memo=None, prefix="")
test/wrapper.py:167
↓ 8 callersMethodbackward
(ctx, grad_out)
lycoris/functional/loha.py:18
↓ 8 callersFunctionreset_globals
()
test/wrapper.py:15
↓ 6 callersFunctionproduct
(xs: list[int | float])
lycoris/utils/general.py:1
↓ 5 callersFunctioncreate_lycoris_from_weights
(multiplier, file, module, weights_sd=None, **kwargs)
lycoris/wrapper.py:140
↓ 5 callersFunctionextract_step
(file_path)
tools/batch_bundle_convert.py:102
↓ 5 callersMethodmatch_fn
(self, pattern: str, name: str)
lycoris/wrapper.py:541
↓ 4 callersMethod__init__
(self, dim)
test/wrapper.py:38
↓ 4 callersMethodbypass_forward_diff
(self, x, scale=1)
lycoris/modules/ia3.py:123
↓ 4 callersFunctionget_module
(lyco_state_dict, lora_name)
lycoris/modules/__init__.py:35
↓ 4 callersFunctionget_r
(oft_blocks, I=None, constraint=0)
lycoris/functional/diag_oft.py:10
↓ 4 callersMethodget_weight
(self, shape)
lycoris/modules/loha.py:194
↓ 4 callersFunctionmake_module
(lyco_type: LycorisBaseModule, params, lora_name, orig_module)
lycoris/modules/__init__.py:43
↓ 4 callersMethodmatch
(key, regex_text)
tools/batch_hcp_convert.py:253
↓ 4 callersMethodmatch_fn
(self, pattern: str, name: str)
lycoris/kohya.py:626
↓ 4 callersFunctionrebuild_tucker
(t, wa, wb)
lycoris/functional/general.py:9
↓ 4 callersMethodto_dict
(self)
lycoris/config_sdk.py:196
↓ 3 callersFunction_copy_value
(value: Any)
lycoris/config_sdk.py:218
↓ 3 callersMethod_run_merge_cycle
(*, precise: bool, cycles: int)
test/precision_merge_test.py:54
↓ 3 callersMethodapply_max_norm
(self, max_norm, device=None)
lycoris/modules/lokr.py:443
↓ 3 callersMethodget_diff_weight
Compute the weight difference: current - base. For T-LoRA: ΔW = P @ diag(λ*mask) @ Q - P_base @ diag(λ_base*mask) @ Q_base
lycoris/modules/tlora.py:373
↓ 3 callersMethodget_merged_weight
(self, multiplier=1.0, shape=None, device=None)
lycoris/modules/base.py:408
↓ 3 callersMethodget_weight
(self, rank)
lycoris/modules/dylora.py:97
↓ 3 callersMethodget_weight
(self, shape)
lycoris/modules/lokr.py:358
↓ 3 callersFunctionload_state_dict
(file_path)
tools/batch_bundle_convert.py:13
↓ 3 callersMethodmake_weight
(self, scale=1, device=None, diff=False)
lycoris/modules/boft.py:145
↓ 3 callersMethodmake_weight
(self, device=None)
lycoris/modules/locon.py:198
↓ 3 callersMethodmake_weight
(self, scale=1, device=None, diff=False)
lycoris/modules/diag_oft.py:131
↓ 3 callersMethodreplace_all
(data: str, srcs: List[str], dsts: List[str])
tools/batch_hcp_convert.py:298
↓ 3 callersFunctionsave_and_print_path
(sd, path)
tools/batch_hcp_convert.py:459
↓ 3 callersFunctionsave_state_dict
(state, output_path)
tools/batch_bundle_convert.py:25
↓ 2 callersMethod_bypass_forward
(self, x, scale=1, diff=False)
lycoris/modules/ia3.py:114
↓ 2 callersMethod_bypass_forward
(self, x, scale=1, diff=False)
lycoris/modules/boft.py:202
↓ 2 callersMethod_bypass_forward
(self, x, scale=1, diff=False)
lycoris/modules/diag_oft.py:173
↓ 2 callersMethod_bypass_forward
(self, x, scale=1, diff=False)
lycoris/modules/glora.py:210
↓ 2 callersMethod_current_bias
(self)
lycoris/modules/base.py:295
↓ 2 callersMethod_get_mask
Get the current timestep mask, defaulting to all ones.
lycoris/modules/tlora.py:326
↓ 2 callersMethodalpha_scale_from_webui
(state)
tools/batch_hcp_convert.py:304
↓ 2 callersMethodapply_weight_decompose
(self, weight, multiplier=1)
lycoris/modules/lokr.py:399
↓ 2 callersMethodapply_weight_decompose
(self, weight, multiplier=1)
lycoris/modules/loha.py:244
↓ 2 callersMethodapply_weight_decompose
(self, weight, multiplier=1)
lycoris/modules/locon.py:239
↓ 2 callersFunctionbuild_wrappers
(module: nn.Module)
example/high_precision_merge_demo.py:31
↓ 2 callersMethodbypass_forward
Forward with bypass mode (compute LoRA separately).
lycoris/modules/tlora.py:517
↓ 2 callersFunctionconvert_diffusers_name_to_compvis
(key)
lycoris/utils/__init__.py:372
↓ 2 callersMethodconvert_from_webui_
(self, state, network_type, prefix, com_name, com_name_tmp)
tools/batch_hcp_convert.py:116
↓ 2 callersMethodconvert_from_webui_xl_te_
( self, state, network_type, prefix, com_name, com_name_tmp )
tools/batch_hcp_convert.py:188
↓ 2 callersFunctionconvert_lora_name
(network_path, dst_dir, to_bundle)
tools/batch_bundle_convert.py:182
↓ 2 callersMethodconvert_to_webui
( self, sd_unet, sd_te, network_type="lora", auto_scale_alpha=False, sdxl=False )
tools/batch_hcp_convert.py:96
↓ 2 callersMethodconvert_to_webui_
(self, state, network_type, prefix)
tools/batch_hcp_convert.py:136
↓ 2 callersMethodconvert_to_webui_
(self, ft_state, base_state, prefix)
tools/batch_hcp_convert.py:368
↓ 2 callersFunctionevaluate
()
example/stacked_wrapper_demo.py:165
↓ 2 callersFunctionextract_conv
( weight: Union[torch.Tensor, nn.Parameter], mode="fixed", mode_param=0, device="cpu", is_
lycoris/utils/__init__.py:60
↓ 2 callersFunctionextract_diff
( base_tes, db_tes, base_unet, db_unet, mode="fixed", linear_mode_param=0, conv_mo
lycoris/utils/__init__.py:158
↓ 2 callersFunctiongather_files_from_list
Gather files from given paths based on specific extensions. Args: paths (List[str]): A list of paths which can be files or directories.
tools/batch_bundle_convert.py:112
↓ 2 callersMethodget_diff_weight
(self, multiplier=1.0, shape=None, device=None)
lycoris/modules/glora.py:200
↓ 2 callersMethodget_r
(self)
lycoris/modules/boft.py:131
↓ 2 callersMethodget_r
(self)
lycoris/modules/diag_oft.py:118
↓ 2 callersMethodget_random_rank_weight
(self)
lycoris/modules/dylora.py:108
↓ 2 callersFunctionis_extension_valid
(file: str)
tools/batch_hcp_convert.py:406
↓ 2 callersFunctionis_extension_valid
(file: str)
tools/batch_bundle_convert.py:127
↓ 2 callersFunctionload_state_dict
(file_path)
tools/pack_bundle.py:44
↓ 2 callersFunctionlogging_force_full_matrix
(lora_dim, dim, factor)
lycoris/modules/lokr.py:15
↓ 2 callersFunctionmake_kron
(w1, w2, scale)
lycoris/functional/lokr.py:11
↓ 2 callersFunctionmake_state_dict
( prefix, root_module: torch.nn.Module, target_module: torch.nn.Module, target
lycoris/utils/__init__.py:189
↓ 2 callersMethodmake_weight
(self, multiplier=1, shape=None, device=None, diff=False)
lycoris/modules/ia3.py:91
↓ 2 callersMethodmake_weight
(self, scale=1, device=None)
lycoris/modules/full.py:150
↓ 2 callersFunctionmerge_state_dict
( prefix, root_module: torch.nn.Module, lyco_state_dict: Dict[str, torch.Tensor],
lycoris/utils/__init__.py:428
↓ 2 callersFunctionpower2factorization
m = 2k n = 2**p m*n = dim
lycoris/functional/general.py:59
↓ 2 callersFunctionread_preset
(preset_path)
lycoris/utils/preset.py:6
↓ 2 callersFunctionreset_preset
()
example/high_precision_merge_demo.py:9
↓ 2 callersFunctionrun_cycles
( module: nn.Linear, wrappers: list[LycorisNetwork], *, precise: bool, cycles: int )
example/high_precision_merge_demo.py:49
↓ 2 callersFunctionwarning_once
(msg)
lycoris/logging.py:46
↓ 1 callersMethod__init__
(self)
lycoris/modules/base.py:18
↓ 1 callersMethod_apply_merged_weights
( self, ctx: _MergeContext, weight: torch.Tensor, bias: torch.Tensor | None,
lycoris/modules/base.py:472
↓ 1 callersMethod_apply_precise_weights
( self, ctx: _MergeContext, weight_prec: torch.Tensor, bias_prec: torch.Tensor
lycoris/modules/base.py:538
↓ 1 callersMethod_compute_precise_result
( self, ctx: _MergeContext, multiplier: float )
lycoris/modules/base.py:510
↓ 1 callersMethod_ensure_precise_snapshot
( module: nn.Module, weight: torch.Tensor, bias: torch.Tensor | None, )
lycoris/modules/base.py:559
↓ 1 callersMethod_initialize_from_svd
Initialize Q and P layers using SVD.
lycoris/modules/tlora.py:247
↓ 1 callersMethod_load_precise_snapshot
( module: nn.Module, weight_param: torch.Tensor, bias_param: torch.Tensor | None,
lycoris/modules/base.py:590
↓ 1 callersMethod_prepare_merge_context
(self, precise: bool)
lycoris/modules/base.py:429
↓ 1 callersMethod_restore_merge_context
(self, ctx: _MergeContext)
lycoris/modules/base.py:502
↓ 1 callersFunctionadd_files_from_directory
(directory: str)
tools/batch_hcp_convert.py:409
↓ 1 callersFunctionadd_files_from_directory
(directory: str)
tools/batch_bundle_convert.py:130
↓ 1 callersMethodalgo_check
(cls, state_dict, lora_name)
lycoris/modules/base.py:265
↓ 1 callersMethodalpha_scale_to_webui
(state)
tools/batch_hcp_convert.py:314
↓ 1 callersMethodapply_preset
(cls, preset)
lycoris/kohya.py:299
↓ 1 callersFunctionapply_wrapper
( model: nn.Module, preset: dict[str, list[str]], **kwargs )
example/stacked_wrapper_demo.py:42
↓ 1 callersFunctionbutterfly_factor
(dimension: int, factor: int = -1)
lycoris/modules/boft.py:24
next →1–100 of 372, ranked by callers