bbliangxin bbliangxin
关注数: 31 粉丝数: 53 发帖数: 2,845 关注贴吧数: 53
请教大佬,训练lora模型出错 搞一天了。。也不知道问题到底出在哪 Folder 10_chinab: 360 steps max_train_steps = 1800 stop_text_encoder_training = 0 lr_warmup_steps = 180 accelerate launch --num_cpu_threads_per_process=2 "train_network.py" --enable_bucket --pretrained_model_name_or_path="D:/Programs/novelai-webu/novelai-webui-aki-v3/models/Stable-diffusion/v1-5-pruned-emaonly.ckpt" --train_data_dir="D:/Programs/novelai-webu/novelai-webui-aki-v3/train/chinab/chinab_out" --resolution=1024,1024 --output_dir="D:/Programs/kohya_ss/weds1_/model" --logging_dir="D:/Programs/kohya_ss/weds1_/log" --network_alpha="1" --save_model_as=safetensors --network_module=networks.lora --text_encoder_lr=5e-5 --unet_lr=0.0001 --network_dim=8 --output_name="chinabbb" --lr_scheduler_num_cycles="5" --learning_rate="0.0001" --lr_scheduler="cosine_with_restarts" --lr_warmup_steps="180" --train_batch_size="1" --max_train_steps="1800" --save_every_n_epochs="5" --mixed_precision="fp16" --save_precision="fp16" --cache_latents --optimizer_type="Lion" --bucket_reso_steps=64 --xformers --bucket_no_upscale prepare tokenizer Use DreamBooth method. prepare train images. found directory 10_chinab contains 36 image files 360 train images with repeating. loading image sizes. 100%|██████████████████████████████████████████████████████████████████████████████████████████████| 36/36 [00:00<00:00, 5158.34it/s] make buckets min_bucket_reso and max_bucket_reso are ignored if bucket_no_upscale is set, because bucket reso is defined by image size automatically / bucket_no_upscaleが指定された場合は、bucketの解像度は画像サイズから自動計算されるため、min_bucket_resoとmax_bucket_resoは無視され ます number of images (including repeats) / 各bucketの画像枚数(繰り返し回数を含む) bucket 0: resolution (512, 512), count: 360 mean ar error (without repeats): 0.0 prepare accelerator Using accelerator 0.15.0 or above. load StableDiffusion checkpoint loading u-net: <All keys matched successfully> loading vae: <All keys matched successfully> Traceback (most recent call last): File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 415, in load_state_dict return torch.load(checkpoint_file, map_location="cpu") File "D:\Programs\kohya_ss\venv\lib\site-packages\torch\serialization.py", line 705, in load with _open_zipfile_reader(opened_file) as opened_zipfile: File "D:\Programs\kohya_ss\venv\lib\site-packages\torch\serialization.py", line 242, in __init__ super(_open_zipfile_reader, self).__init__(torch._C.PyTorchFileReader(name_or_buffer)) RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central directory During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 419, in load_state_dict if f.read(7) == "version": UnicodeDecodeError: 'gbk' codec can't decode byte 0x80 in position 64: illegal multibyte sequence During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:\Programs\kohya_ss\train_network.py", line 507, in <module> train(args) File "D:\Programs\kohya_ss\train_network.py", line 96, in train text_encoder, vae, unet, _ = train_util.load_target_model(args, weight_dtype) File "D:\Programs\kohya_ss\library\train_util.py", line 1860, in load_target_model text_encoder, vae, unet = model_util.load_models_from_stable_diffusion_checkpoint(args.v2, name_or_path) File "D:\Programs\kohya_ss\library\model_util.py", line 919, in load_models_from_stable_diffusion_checkpoint text_model = CLIPTextModel.from_pretrained("openai/clip-vit-large-patch14") File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 2301, in from_pretrained state_dict = load_state_dict(resolved_archive_file) File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 431, in load_state_dict raise OSError( OSError: Unable to load weights from pytorch checkpoint file for 'C:\Users\lx/.cache\huggingface\hub\models--openai--clip-vit-large-patch14\snapshots\8d052a0f05efbaefbc9e8786ba291cfdf93e5bff\pytorch_model.bin' at 'C:\Users\lx/.cache\huggingface\hub\models--openai--clip-vit-large-patch14\snapshots\8d052a0f05efbaefbc9e8786ba291cfdf93e5bff\pytorch_model.bin'. If you tried to load a PyTorch model from a TF 2.0 checkpoint, please set from_tf=True. Traceback (most recent call last): File "D:\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "D:\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "D:\Programs\kohya_ss\venv\Scripts\accelerate.exe\__main__.py", line 7, in <module> File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\accelerate_cli.py", line 45, in main args.func(args) File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 1104, in launch_command simple_launcher(args) File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 567, in simple_launcher raise subprocess.CalledProcessError(returncode=process.returncode, cmd=cmd) subprocess.CalledProcessError: Command '['D:\\Programs\\kohya_ss\\venv\\Scripts\\python.exe', 'train_network.py', '--enable_bucket', '--pretrained_model_name_or_path=D:/Programs/novelai-webu/novelai-webui-aki-v3/models/Stable-diffusion/v1-5-pruned-emaonly.ckpt', '--train_data_dir=D:/Programs/novelai-webu/novelai-webui-aki-v3/train/chinab/chinab_out', '--resolution=1024,1024', '--output_dir=D:/Programs/kohya_ss/weds1_/model', '--logging_dir=D:/Programs/kohya_ss/weds1_/log', '--network_alpha=1', '--save_model_as=safetensors', '--network_module=networks.lora', '--text_encoder_lr=5e-5', '--unet_lr=0.0001', '--network_dim=8', '--output_name=chinabbb', '--lr_scheduler_num_cycles=5', '--learning_rate=0.0001', '--lr_scheduler=cosine_with_restarts', '--lr_warmup_steps=180', '--train_batch_size=1', '--max_train_steps=1800', '--save_every_n_epochs=5', '--mixed_precision=fp16', '--save_precision=fp16', '--cache_latents', '--optimizer_type=Lion', '--bucket_reso_steps=64', '--xformers', '--bucket_no_upscale']' returned non-zero exit status 1. Folder 10_chinab: 360 steps max_train_steps = 1800 stop_text_encoder_training = 0 lr_warmup_steps = 180 accelerate launch --num_cpu_threads_per_process=2 "train_network.py" --enable_bucket --pretrained_model_name_or_path="D:/Programs/novelai-webu/novelai-webui-aki-v3/models/Stable-diffusion/v1-5-pruned-emaonly.ckpt" --train_data_dir="D:/Programs/novelai-webu/novelai-webui-aki-v3/train/chinab/chinab_out" --resolution=1024,1024 --output_dir="D:/Programs/kohya_ss/weds1_/model" --logging_dir="D:/Programs/kohya_ss/weds1_/log" --network_alpha="1" --save_model_as=safetensors --network_module=networks.lora --text_encoder_lr=5e-5 --unet_lr=0.0001 --network_dim=8 --output_name="chinabbb" --lr_scheduler_num_cycles="5" --learning_rate="0.0001" --lr_scheduler="cosine_with_restarts" --lr_warmup_steps="180" --train_batch_size="1" --max_train_steps="1800" --save_every_n_epochs="5" --mixed_precision="fp16" --save_precision="fp16" --cache_latents --optimizer_type="Lion" --bucket_reso_steps=64 --xformers --bucket_no_upscale prepare tokenizer Use DreamBooth method. prepare train images. found directory 10_chinab contains 36 image files 360 train images with repeating. loading image sizes. 100%|██████████████████████████████████████████████████████████████████████████████████████████████| 36/36 [00:00<00:00, 7809.41it/s] make buckets min_bucket_reso and max_bucket_reso are ignored if bucket_no_upscale is set, because bucket reso is defined by image size automatically / bucket_no_upscaleが指定された場合は、bucketの解像度は画像サイズから自動計算されるため、min_bucket_resoとmax_bucket_resoは無視され ます number of images (including repeats) / 各bucketの画像枚数(繰り返し回数を含む) bucket 0: resolution (512, 512), count: 360 mean ar error (without repeats): 0.0 prepare accelerator Using accelerator 0.15.0 or above. load StableDiffusion checkpoint loading u-net: <All keys matched successfully> loading vae: <All keys matched successfully> Traceback (most recent call last): File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 415, in load_state_dict return torch.load(checkpoint_file, map_location="cpu") File "D:\Programs\kohya_ss\venv\lib\site-packages\torch\serialization.py", line 705, in load with _open_zipfile_reader(opened_file) as opened_zipfile: File "D:\Programs\kohya_ss\venv\lib\site-packages\torch\serialization.py", line 242, in __init__ super(_open_zipfile_reader, self).__init__(torch._C.PyTorchFileReader(name_or_buffer)) RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central directory During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 419, in load_state_dict if f.read(7) == "version": UnicodeDecodeError: 'gbk' codec can't decode byte 0x80 in position 64: illegal multibyte sequence During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:\Programs\kohya_ss\train_network.py", line 507, in <module> train(args) File "D:\Programs\kohya_ss\train_network.py", line 96, in train text_encoder, vae, unet, _ = train_util.load_target_model(args, weight_dtype) File "D:\Programs\kohya_ss\library\train_util.py", line 1860, in load_target_model text_encoder, vae, unet = model_util.load_models_from_stable_diffusion_checkpoint(args.v2, name_or_path) File "D:\Programs\kohya_ss\library\model_util.py", line 919, in load_models_from_stable_diffusion_checkpoint text_model = CLIPTextModel.from_pretrained("openai/clip-vit-large-patch14") File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 2301, in from_pretrained state_dict = load_state_dict(resolved_archive_file) File "D:\Programs\kohya_ss\venv\lib\site-packages\transformers\modeling_utils.py", line 431, in load_state_dict raise OSError( OSError: Unable to load weights from pytorch checkpoint file for 'C:\Users\lx/.cache\huggingface\hub\models--openai--clip-vit-large-patch14\snapshots\8d052a0f05efbaefbc9e8786ba291cfdf93e5bff\pytorch_model.bin' at 'C:\Users\lx/.cache\huggingface\hub\models--openai--clip-vit-large-patch14\snapshots\8d052a0f05efbaefbc9e8786ba291cfdf93e5bff\pytorch_model.bin'. If you tried to load a PyTorch model from a TF 2.0 checkpoint, please set from_tf=True. Traceback (most recent call last): File "D:\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "D:\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "D:\Programs\kohya_ss\venv\Scripts\accelerate.exe\__main__.py", line 7, in <module> File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\accelerate_cli.py", line 45, in main args.func(args) File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 1104, in launch_command simple_launcher(args) File "D:\Programs\kohya_ss\venv\lib\site-packages\accelerate\commands\launch.py", line 567, in simple_launcher raise subprocess.CalledProcessError(returncode=process.returncode, cmd=cmd) subprocess.CalledProcessError: Command '['D:\\Programs\\kohya_ss\\venv\\Scripts\\python.exe', 'train_network.py', '--enable_bucket', '--pretrained_model_name_or_path=D:/Programs/novelai-webu/novelai-webui-aki-v3/models/Stable-diffusion/v1-5-pruned-emaonly.ckpt', '--train_data_dir=D:/Programs/novelai-webu/novelai-webui-aki-v3/train/chinab/chinab_out', '--resolution=1024,1024', '--output_dir=D:/Programs/kohya_ss/weds1_/model', '--logging_dir=D:/Programs/kohya_ss/weds1_/log', '--network_alpha=1', '--save_model_as=safetensors', '--network_module=networks.lora', '--text_encoder_lr=5e-5', '--unet_lr=0.0001', '--network_dim=8', '--output_name=chinabbb', '--lr_scheduler_num_cycles=5', '--learning_rate=0.0001', '--lr_scheduler=cosine_with_restarts', '--lr_warmup_steps=180', '--train_batch_size=1', '--max_train_steps=1800', '--save_every_n_epochs=5', '--mixed_precision=fp16', '--save_precision=fp16', '--cache_latents', '--optimizer_type=Lion', '--bucket_reso_steps=64', '--xformers', '--bucket_no_upscale']' returned non-zero exit status 1.
今天打出了5代三角头结局,忽然想到了游戏里为什么三角头不杀主角 一直不明白为什么在游戏里那次三角头跟主角对视半天但又扭头离开,而且在整个游戏里,主角都没有跟三角头正面冲突过的原因。。。今天打出了三角头结局里,2个三角头给主角戴上了三角面具,主角也成了第3个三角头,第3个,忽然想到牧羊小镇建镇正好是150年,而根据游戏里的提示,每隔50年四大家族就需要献上一次他们的孩子,而正好,主角这代是第三次献祭,我想会不会那两个三角头就是前两次献祭的主角家族里的孩子,而他们不杀主角的原因就是看主角有变三角头的潜力,杀了主角的父亲是因为一方面他们能感觉到主角对父亲的恨意(因为他们都有类似的遭遇),另一方面,这样也能让主角更容易思想陷入崩溃的状况,而成为新的三角头。想到这里,可能有朋友会想到一个问题,就是150年,四大家族的祖先第一次来到这个镇子上时有没有立刻献祭主角的孩子,如果这样算的话,主角这代就是第4次献祭了,那么前面说的也就说不通了,但我猜想,四大家族第一次来到这个镇子上的时候,可能没有立刻献祭自己的孩子,但由于他们的信仰,镇子上可能会发生一些怪事,他们可能会认为是神的报复,而在50年之后,第一次献上了自己的孩子。。这样也比较符合人的思想。。。。猜的对不对,还请大家多包涵。。。
1 下一页