i need help i get this error when trying to run the kohya train for flux : Traceback (most recent c

i need help i get this error when trying to run the kohya train for flux :
Traceback (most recent call last):
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\sd-scripts\flux_train_network.py", line 411, in <module>
trainer.train(args)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\sd-scripts\train_network.py", line 390, in train
self.cache_text_encoder_outputs_if_needed(args, accelerator, unet, vae, text_encoders, train_dataset_group, weight_dtype)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\sd-scripts\flux_train_network.py", line 160, in cache_text_encoder_outputs_if_needed
unet.to("cpu")
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\torch\nn\modules\module.py", line 1174, in to
return self._apply(convert)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\torch\nn\modules\module.py", line 780, in _apply
module._apply(fn)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\torch\nn\modules\module.py", line 805, in _apply
param_applied = fn(param)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\torch\nn\modules\module.py", line 1167, in convert
raise NotImplementedError(
NotImplementedError: Cannot copy out of meta tensor; no data! Please use torch.nn.Module.to_empty() instead of torch.nn.Module.to() when moving module from meta to a different device.
Traceback (most recent call last):
File "C:\Users\Surikata\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\Surikata\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\Scripts\accelerate.EXE__main__.py", line 7, in <module>
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\accelerate\commands\accelerate_cli.py", line 48, in main
args.func(args)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 1106, in launch_command
simple_launcher(args)
File "F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 704, in simple_launcher
raise subprocess.CalledProcessError(returncode=process.returncode, cmd=cmd)
subprocess.CalledProcessError: Command '['F:\kohyaflux\Kohya_GUI_Flux_Installer_v1\kohya_ss\venv\Scripts\python.exe', 'F:/kohyaflux/Kohya_GUI_Flux_Installer_v1/kohya_ss/sd-scripts/flux_train_network.py', '--config_file', 'F:/AISTUFF/train/model/config_lora-20240822-185636.toml']' returned non-zero exit status 1.
18:56:49-324344 INFO Training has ended.
Was this page helpful?