2023-06-17 00:00:37 +02:00
|
|
|
import functools
|
2023-08-11 19:41:33 +02:00
|
|
|
from collections import OrderedDict
|
2023-06-17 00:00:37 +02:00
|
|
|
|
|
|
|
|
import gradio as gr
|
|
|
|
|
|
2023-08-11 19:41:33 +02:00
|
|
|
loaders_and_params = OrderedDict({
|
2025-04-22 01:36:35 +02:00
|
|
|
'llama.cpp': [
|
2025-05-13 21:07:59 +02:00
|
|
|
'gpu_layers',
|
2025-04-22 01:36:35 +02:00
|
|
|
'threads',
|
|
|
|
|
'threads_batch',
|
|
|
|
|
'batch_size',
|
2025-04-26 01:59:03 +02:00
|
|
|
'ctx_size',
|
2025-04-22 01:36:35 +02:00
|
|
|
'cache_type',
|
|
|
|
|
'tensor_split',
|
2025-04-25 16:32:51 +02:00
|
|
|
'extra_flags',
|
2025-04-26 02:32:00 +02:00
|
|
|
'streaming_llm',
|
2025-04-22 01:36:35 +02:00
|
|
|
'rope_freq_base',
|
|
|
|
|
'compress_pos_emb',
|
|
|
|
|
'flash_attn',
|
|
|
|
|
'row_split',
|
|
|
|
|
'no_kv_offload',
|
|
|
|
|
'no_mmap',
|
|
|
|
|
'mlock',
|
|
|
|
|
'numa',
|
2025-04-24 01:10:16 +02:00
|
|
|
'model_draft',
|
|
|
|
|
'draft_max',
|
|
|
|
|
'gpu_layers_draft',
|
|
|
|
|
'device_draft',
|
|
|
|
|
'ctx_size_draft',
|
2025-04-25 05:11:04 +02:00
|
|
|
'speculative_decoding_accordion',
|
2025-05-16 06:42:15 +02:00
|
|
|
'vram_info',
|
2025-04-22 01:36:35 +02:00
|
|
|
],
|
2023-08-11 19:41:33 +02:00
|
|
|
'Transformers': [
|
2025-04-20 18:33:47 +02:00
|
|
|
'gpu_split',
|
2025-01-10 22:04:32 +01:00
|
|
|
'cpu_memory',
|
|
|
|
|
'alpha_value',
|
|
|
|
|
'compress_pos_emb',
|
|
|
|
|
'compute_dtype',
|
|
|
|
|
'quant_type',
|
2023-08-11 19:41:33 +02:00
|
|
|
'load_in_8bit',
|
2025-01-10 22:04:32 +01:00
|
|
|
'load_in_4bit',
|
2025-07-10 03:38:45 +02:00
|
|
|
'attn_implementation',
|
2023-08-11 19:41:33 +02:00
|
|
|
'cpu',
|
|
|
|
|
'disk',
|
|
|
|
|
'use_double_quant',
|
2025-01-10 22:04:32 +01:00
|
|
|
'bf16',
|
2023-08-11 19:41:33 +02:00
|
|
|
'trust_remote_code',
|
2023-11-17 04:45:05 +01:00
|
|
|
'no_use_fast',
|
2023-08-11 19:41:33 +02:00
|
|
|
],
|
2025-04-09 05:07:08 +02:00
|
|
|
'ExLlamav3_HF': [
|
2025-04-26 01:59:03 +02:00
|
|
|
'ctx_size',
|
2025-04-26 02:32:00 +02:00
|
|
|
'cache_type',
|
2025-04-09 05:07:08 +02:00
|
|
|
'gpu_split',
|
|
|
|
|
'cfg_cache',
|
|
|
|
|
'trust_remote_code',
|
|
|
|
|
'no_use_fast',
|
|
|
|
|
],
|
2025-08-09 04:31:16 +02:00
|
|
|
'ExLlamav3': [
|
|
|
|
|
'ctx_size',
|
|
|
|
|
'cache_type',
|
|
|
|
|
'gpu_split',
|
|
|
|
|
],
|
2023-12-17 16:08:33 +01:00
|
|
|
'ExLlamav2_HF': [
|
2025-04-26 01:59:03 +02:00
|
|
|
'ctx_size',
|
2024-12-17 21:43:48 +01:00
|
|
|
'cache_type',
|
2025-01-10 22:04:32 +01:00
|
|
|
'gpu_split',
|
2023-08-11 19:41:33 +02:00
|
|
|
'alpha_value',
|
|
|
|
|
'compress_pos_emb',
|
2025-01-10 22:04:32 +01:00
|
|
|
'num_experts_per_token',
|
|
|
|
|
'autosplit',
|
|
|
|
|
'enable_tp',
|
|
|
|
|
'no_flash_attn',
|
|
|
|
|
'no_xformers',
|
|
|
|
|
'no_sdpa',
|
|
|
|
|
'cfg_cache',
|
2023-12-08 15:29:26 +01:00
|
|
|
'trust_remote_code',
|
2023-11-17 04:45:05 +01:00
|
|
|
'no_use_fast',
|
2023-08-11 19:41:33 +02:00
|
|
|
],
|
2024-02-06 15:21:17 +01:00
|
|
|
'ExLlamav2': [
|
2025-04-26 01:59:03 +02:00
|
|
|
'ctx_size',
|
2024-12-17 21:43:48 +01:00
|
|
|
'cache_type',
|
2025-01-10 22:04:32 +01:00
|
|
|
'gpu_split',
|
2024-02-06 15:21:17 +01:00
|
|
|
'alpha_value',
|
|
|
|
|
'compress_pos_emb',
|
2025-01-10 22:04:32 +01:00
|
|
|
'num_experts_per_token',
|
|
|
|
|
'autosplit',
|
|
|
|
|
'enable_tp',
|
|
|
|
|
'no_flash_attn',
|
|
|
|
|
'no_xformers',
|
|
|
|
|
'no_sdpa',
|
2025-04-25 05:11:04 +02:00
|
|
|
'model_draft',
|
2025-04-27 03:01:33 +02:00
|
|
|
'draft_max',
|
2025-04-25 05:11:04 +02:00
|
|
|
'ctx_size_draft',
|
|
|
|
|
'speculative_decoding_accordion',
|
2024-02-06 15:21:17 +01:00
|
|
|
],
|
2024-06-24 07:30:03 +02:00
|
|
|
'TensorRT-LLM': [
|
2025-04-26 01:59:03 +02:00
|
|
|
'ctx_size',
|
2024-06-24 07:30:03 +02:00
|
|
|
'cpp_runner',
|
|
|
|
|
'tensorrt_llm_info',
|
2023-12-06 04:01:01 +01:00
|
|
|
]
|
2023-08-11 19:41:33 +02:00
|
|
|
})
|
2023-06-17 00:00:37 +02:00
|
|
|
|
2023-12-21 04:18:07 +01:00
|
|
|
|
|
|
|
|
def transformers_samplers():
|
|
|
|
|
return {
|
2023-08-01 03:44:00 +02:00
|
|
|
'temperature',
|
2024-01-09 03:28:35 +01:00
|
|
|
'dynatemp_low',
|
|
|
|
|
'dynatemp_high',
|
|
|
|
|
'dynatemp_exponent',
|
2024-02-04 04:20:02 +01:00
|
|
|
'smoothing_factor',
|
2024-03-03 17:22:21 +01:00
|
|
|
'smoothing_curve',
|
2023-11-02 20:32:51 +01:00
|
|
|
'min_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'top_p',
|
2023-08-01 03:44:00 +02:00
|
|
|
'top_k',
|
|
|
|
|
'typical_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'xtc_threshold',
|
|
|
|
|
'xtc_probability',
|
2023-08-01 03:44:00 +02:00
|
|
|
'epsilon_cutoff',
|
|
|
|
|
'eta_cutoff',
|
|
|
|
|
'tfs',
|
|
|
|
|
'top_a',
|
2025-03-14 20:45:11 +01:00
|
|
|
'top_n_sigma',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dry_multiplier',
|
|
|
|
|
'dry_allowed_length',
|
|
|
|
|
'dry_base',
|
2023-08-01 03:44:00 +02:00
|
|
|
'repetition_penalty',
|
2023-10-25 17:10:28 +02:00
|
|
|
'frequency_penalty',
|
2025-01-10 22:04:32 +01:00
|
|
|
'presence_penalty',
|
2023-08-01 03:44:00 +02:00
|
|
|
'encoder_repetition_penalty',
|
|
|
|
|
'no_repeat_ngram_size',
|
2025-01-10 22:04:32 +01:00
|
|
|
'repetition_penalty_range',
|
2023-08-01 03:44:00 +02:00
|
|
|
'penalty_alpha',
|
2025-01-10 22:04:32 +01:00
|
|
|
'guidance_scale',
|
2023-08-01 03:44:00 +02:00
|
|
|
'mirostat_mode',
|
|
|
|
|
'mirostat_tau',
|
|
|
|
|
'mirostat_eta',
|
2025-01-10 22:04:32 +01:00
|
|
|
'prompt_lookup_num_tokens',
|
|
|
|
|
'do_sample',
|
|
|
|
|
'dynamic_temperature',
|
|
|
|
|
'temperature_last',
|
|
|
|
|
'auto_max_new_tokens',
|
2023-08-01 03:44:00 +02:00
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
2025-04-29 07:37:01 +02:00
|
|
|
'enable_thinking',
|
2025-08-06 00:19:11 +02:00
|
|
|
'reasoning_effort',
|
2023-08-01 03:44:00 +02:00
|
|
|
'skip_special_tokens',
|
2025-01-05 02:52:57 +01:00
|
|
|
'static_cache',
|
2025-01-10 22:04:32 +01:00
|
|
|
'seed',
|
|
|
|
|
'sampler_priority',
|
|
|
|
|
'custom_token_bans',
|
|
|
|
|
'negative_prompt',
|
|
|
|
|
'dry_sequence_breakers',
|
|
|
|
|
'grammar_string',
|
|
|
|
|
'grammar_file_row',
|
2023-12-21 04:18:07 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
loaders_samplers = {
|
|
|
|
|
'Transformers': transformers_samplers(),
|
2025-04-09 05:07:08 +02:00
|
|
|
'ExLlamav3_HF': {
|
2024-02-06 15:21:17 +01:00
|
|
|
'temperature',
|
2025-01-05 01:22:59 +01:00
|
|
|
'dynatemp_low',
|
|
|
|
|
'dynatemp_high',
|
|
|
|
|
'dynatemp_exponent',
|
2025-01-10 22:04:32 +01:00
|
|
|
'smoothing_factor',
|
2025-04-09 05:07:08 +02:00
|
|
|
'smoothing_curve',
|
2024-02-06 15:21:17 +01:00
|
|
|
'min_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'top_p',
|
2024-02-06 15:21:17 +01:00
|
|
|
'top_k',
|
|
|
|
|
'typical_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'xtc_threshold',
|
|
|
|
|
'xtc_probability',
|
2025-04-09 05:07:08 +02:00
|
|
|
'epsilon_cutoff',
|
|
|
|
|
'eta_cutoff',
|
2024-02-06 15:21:17 +01:00
|
|
|
'tfs',
|
|
|
|
|
'top_a',
|
2025-04-09 05:07:08 +02:00
|
|
|
'top_n_sigma',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dry_multiplier',
|
|
|
|
|
'dry_allowed_length',
|
|
|
|
|
'dry_base',
|
2024-02-06 15:21:17 +01:00
|
|
|
'repetition_penalty',
|
|
|
|
|
'frequency_penalty',
|
2025-01-10 22:04:32 +01:00
|
|
|
'presence_penalty',
|
2025-04-09 05:07:08 +02:00
|
|
|
'encoder_repetition_penalty',
|
|
|
|
|
'no_repeat_ngram_size',
|
2024-02-06 15:21:17 +01:00
|
|
|
'repetition_penalty_range',
|
2025-04-09 05:07:08 +02:00
|
|
|
'guidance_scale',
|
2024-02-06 15:21:17 +01:00
|
|
|
'mirostat_mode',
|
|
|
|
|
'mirostat_tau',
|
|
|
|
|
'mirostat_eta',
|
2025-04-09 05:07:08 +02:00
|
|
|
'do_sample',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dynamic_temperature',
|
|
|
|
|
'temperature_last',
|
|
|
|
|
'auto_max_new_tokens',
|
2024-02-06 15:21:17 +01:00
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
2025-04-29 07:37:01 +02:00
|
|
|
'enable_thinking',
|
2025-08-06 00:19:11 +02:00
|
|
|
'reasoning_effort',
|
2024-02-06 15:21:17 +01:00
|
|
|
'skip_special_tokens',
|
2025-01-10 22:04:32 +01:00
|
|
|
'seed',
|
2025-04-09 05:07:08 +02:00
|
|
|
'sampler_priority',
|
2025-01-10 22:04:32 +01:00
|
|
|
'custom_token_bans',
|
2025-04-09 05:07:08 +02:00
|
|
|
'negative_prompt',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dry_sequence_breakers',
|
2025-04-09 05:07:08 +02:00
|
|
|
'grammar_string',
|
|
|
|
|
'grammar_file_row',
|
2024-02-06 15:21:17 +01:00
|
|
|
},
|
2023-09-12 19:33:07 +02:00
|
|
|
'ExLlamav2_HF': {
|
|
|
|
|
'temperature',
|
2024-01-09 03:28:35 +01:00
|
|
|
'dynatemp_low',
|
|
|
|
|
'dynatemp_high',
|
|
|
|
|
'dynatemp_exponent',
|
2024-02-04 04:20:02 +01:00
|
|
|
'smoothing_factor',
|
2024-03-03 17:22:21 +01:00
|
|
|
'smoothing_curve',
|
2023-11-02 20:32:51 +01:00
|
|
|
'min_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'top_p',
|
2023-09-12 19:33:07 +02:00
|
|
|
'top_k',
|
|
|
|
|
'typical_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'xtc_threshold',
|
|
|
|
|
'xtc_probability',
|
2023-09-12 19:33:07 +02:00
|
|
|
'epsilon_cutoff',
|
|
|
|
|
'eta_cutoff',
|
|
|
|
|
'tfs',
|
|
|
|
|
'top_a',
|
2025-03-14 20:45:11 +01:00
|
|
|
'top_n_sigma',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dry_multiplier',
|
|
|
|
|
'dry_allowed_length',
|
|
|
|
|
'dry_base',
|
2023-09-12 19:33:07 +02:00
|
|
|
'repetition_penalty',
|
2023-10-25 17:10:28 +02:00
|
|
|
'frequency_penalty',
|
2025-01-10 22:04:32 +01:00
|
|
|
'presence_penalty',
|
2023-09-12 19:33:07 +02:00
|
|
|
'encoder_repetition_penalty',
|
|
|
|
|
'no_repeat_ngram_size',
|
2025-01-10 22:04:32 +01:00
|
|
|
'repetition_penalty_range',
|
|
|
|
|
'guidance_scale',
|
2023-09-12 19:33:07 +02:00
|
|
|
'mirostat_mode',
|
|
|
|
|
'mirostat_tau',
|
|
|
|
|
'mirostat_eta',
|
2025-01-10 22:04:32 +01:00
|
|
|
'do_sample',
|
|
|
|
|
'dynamic_temperature',
|
|
|
|
|
'temperature_last',
|
|
|
|
|
'auto_max_new_tokens',
|
2023-09-12 19:33:07 +02:00
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
2025-04-29 07:37:01 +02:00
|
|
|
'enable_thinking',
|
2025-08-06 00:19:11 +02:00
|
|
|
'reasoning_effort',
|
2023-09-12 19:33:07 +02:00
|
|
|
'skip_special_tokens',
|
2025-01-10 22:04:32 +01:00
|
|
|
'seed',
|
|
|
|
|
'sampler_priority',
|
|
|
|
|
'custom_token_bans',
|
|
|
|
|
'negative_prompt',
|
|
|
|
|
'dry_sequence_breakers',
|
|
|
|
|
'grammar_string',
|
|
|
|
|
'grammar_file_row',
|
2023-09-12 19:33:07 +02:00
|
|
|
},
|
2025-08-09 04:31:16 +02:00
|
|
|
'ExLlamav3': {
|
|
|
|
|
'temperature',
|
|
|
|
|
'min_p',
|
|
|
|
|
'top_p',
|
|
|
|
|
'top_k',
|
|
|
|
|
'repetition_penalty',
|
|
|
|
|
'frequency_penalty',
|
|
|
|
|
'presence_penalty',
|
|
|
|
|
'repetition_penalty_range',
|
|
|
|
|
'temperature_last',
|
2025-08-09 06:15:53 +02:00
|
|
|
'sampler_priority',
|
2025-08-09 04:31:16 +02:00
|
|
|
'auto_max_new_tokens',
|
|
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
|
|
|
|
'enable_thinking',
|
|
|
|
|
'seed',
|
2025-08-09 06:15:53 +02:00
|
|
|
'skip_special_tokens',
|
2025-08-09 04:31:16 +02:00
|
|
|
},
|
2025-04-09 05:07:08 +02:00
|
|
|
'ExLlamav2': {
|
|
|
|
|
'temperature',
|
|
|
|
|
'dynatemp_low',
|
|
|
|
|
'dynatemp_high',
|
|
|
|
|
'dynatemp_exponent',
|
|
|
|
|
'smoothing_factor',
|
|
|
|
|
'min_p',
|
|
|
|
|
'top_p',
|
|
|
|
|
'top_k',
|
|
|
|
|
'typical_p',
|
|
|
|
|
'xtc_threshold',
|
|
|
|
|
'xtc_probability',
|
|
|
|
|
'tfs',
|
|
|
|
|
'top_a',
|
|
|
|
|
'dry_multiplier',
|
|
|
|
|
'dry_allowed_length',
|
|
|
|
|
'dry_base',
|
|
|
|
|
'repetition_penalty',
|
|
|
|
|
'frequency_penalty',
|
|
|
|
|
'presence_penalty',
|
|
|
|
|
'repetition_penalty_range',
|
|
|
|
|
'mirostat_mode',
|
|
|
|
|
'mirostat_tau',
|
|
|
|
|
'mirostat_eta',
|
|
|
|
|
'dynamic_temperature',
|
|
|
|
|
'temperature_last',
|
|
|
|
|
'auto_max_new_tokens',
|
|
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
2025-04-29 07:37:01 +02:00
|
|
|
'enable_thinking',
|
2025-08-06 00:19:11 +02:00
|
|
|
'reasoning_effort',
|
2025-04-09 05:07:08 +02:00
|
|
|
'skip_special_tokens',
|
|
|
|
|
'seed',
|
|
|
|
|
'custom_token_bans',
|
|
|
|
|
'dry_sequence_breakers',
|
|
|
|
|
},
|
2023-08-01 03:44:00 +02:00
|
|
|
'llama.cpp': {
|
|
|
|
|
'temperature',
|
2024-01-09 03:28:35 +01:00
|
|
|
'dynatemp_low',
|
|
|
|
|
'dynatemp_high',
|
|
|
|
|
'dynatemp_exponent',
|
2023-11-02 20:32:51 +01:00
|
|
|
'min_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'top_p',
|
2023-08-01 03:44:00 +02:00
|
|
|
'top_k',
|
|
|
|
|
'typical_p',
|
2025-01-10 22:04:32 +01:00
|
|
|
'xtc_threshold',
|
|
|
|
|
'xtc_probability',
|
2025-05-06 17:18:49 +02:00
|
|
|
'top_n_sigma',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dry_multiplier',
|
|
|
|
|
'dry_allowed_length',
|
|
|
|
|
'dry_base',
|
2023-08-01 03:44:00 +02:00
|
|
|
'repetition_penalty',
|
2023-10-25 17:10:28 +02:00
|
|
|
'frequency_penalty',
|
2025-01-10 22:04:32 +01:00
|
|
|
'presence_penalty',
|
|
|
|
|
'repetition_penalty_range',
|
2023-08-01 03:44:00 +02:00
|
|
|
'mirostat_mode',
|
|
|
|
|
'mirostat_tau',
|
|
|
|
|
'mirostat_eta',
|
2025-01-10 22:04:32 +01:00
|
|
|
'dynamic_temperature',
|
|
|
|
|
'temperature_last',
|
|
|
|
|
'auto_max_new_tokens',
|
2023-08-01 03:44:00 +02:00
|
|
|
'ban_eos_token',
|
|
|
|
|
'add_bos_token',
|
2025-04-29 07:37:01 +02:00
|
|
|
'enable_thinking',
|
2025-08-06 00:19:11 +02:00
|
|
|
'reasoning_effort',
|
2025-01-10 22:04:32 +01:00
|
|
|
'seed',
|
|
|
|
|
'sampler_priority',
|
|
|
|
|
'dry_sequence_breakers',
|
|
|
|
|
'grammar_string',
|
|
|
|
|
'grammar_file_row',
|
2023-08-01 03:44:00 +02:00
|
|
|
},
|
2024-06-24 07:30:03 +02:00
|
|
|
'TensorRT-LLM': {
|
|
|
|
|
'temperature',
|
|
|
|
|
'top_p',
|
|
|
|
|
'top_k',
|
|
|
|
|
'repetition_penalty',
|
|
|
|
|
'frequency_penalty',
|
2025-01-10 22:04:32 +01:00
|
|
|
'presence_penalty',
|
2024-06-24 07:30:03 +02:00
|
|
|
'auto_max_new_tokens',
|
2025-01-10 22:04:32 +01:00
|
|
|
'ban_eos_token',
|
2024-06-24 07:30:03 +02:00
|
|
|
}
|
2023-08-11 19:41:33 +02:00
|
|
|
}
|
|
|
|
|
|
2023-08-01 03:44:00 +02:00
|
|
|
|
|
|
|
|
@functools.cache
|
|
|
|
|
def list_all_samplers():
|
|
|
|
|
all_samplers = set()
|
|
|
|
|
for k in loaders_samplers:
|
|
|
|
|
for sampler in loaders_samplers[k]:
|
|
|
|
|
all_samplers.add(sampler)
|
|
|
|
|
|
|
|
|
|
return sorted(all_samplers)
|
|
|
|
|
|
|
|
|
|
|
2024-01-09 04:42:31 +01:00
|
|
|
def blacklist_samplers(loader, dynamic_temperature):
|
2023-08-01 03:44:00 +02:00
|
|
|
all_samplers = list_all_samplers()
|
2024-01-09 04:42:31 +01:00
|
|
|
output = []
|
|
|
|
|
|
|
|
|
|
for sampler in all_samplers:
|
|
|
|
|
if loader == 'All' or sampler in loaders_samplers[loader]:
|
|
|
|
|
if sampler.startswith('dynatemp'):
|
|
|
|
|
output.append(gr.update(visible=dynamic_temperature))
|
|
|
|
|
else:
|
|
|
|
|
output.append(gr.update(visible=True))
|
|
|
|
|
else:
|
|
|
|
|
output.append(gr.update(visible=False))
|
|
|
|
|
|
|
|
|
|
return output
|
2023-08-01 03:44:00 +02:00
|
|
|
|
2023-06-17 00:00:37 +02:00
|
|
|
|
|
|
|
|
@functools.cache
|
|
|
|
|
def get_all_params():
|
|
|
|
|
all_params = set()
|
|
|
|
|
for k in loaders_and_params:
|
|
|
|
|
for el in loaders_and_params[k]:
|
|
|
|
|
all_params.add(el)
|
|
|
|
|
|
|
|
|
|
return sorted(all_params)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def make_loader_params_visible(loader):
|
|
|
|
|
params = []
|
|
|
|
|
all_params = get_all_params()
|
|
|
|
|
if loader in loaders_and_params:
|
|
|
|
|
params = loaders_and_params[loader]
|
|
|
|
|
|
|
|
|
|
return [gr.update(visible=True) if k in params else gr.update(visible=False) for k in all_params]
|