You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Basically when I try to run accelerate config it will throw a bunch of errors:
(venv) PS G:!AI\SD\kohya_ss> accelerate config
------------------------------------------------------------------------------------------------------------------------In which compute environment are you running?
Please select a choice using the arrow or number keys, and selecting with enter
Traceback (most recent call last):
File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "G:!AI\SD\kohya_ss\venv\Scripts\accelerate.exe_main.py", line 7, in
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\accelerate_cli.py", line 45, in main
args.func(args)
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config.py", line 67, in config_command
config = get_user_input()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config.py", line 32, in get_user_input
compute_environment = _ask_options(
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config_utils.py", line 58, in _ask_options
result = menu.run(default_choice=default)
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\selection_menu.py", line 118, in run
choice = self.handle_input()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\input.py", line 73, in handle_input
char = get_character()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\keymap.py", line 114, in get_character
char = get_raw_chars()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\keymap.py", line 77, in get_raw_chars
if ch.encode(encoding) in (b"\x00", b"\xe0"):
UnicodeEncodeError: 'mbcs' codec can't encode characters in position 0--1: invalid character
I'm running Polish version of Windows and 852 (OEM - Latin II) codepage for the cmd / powershell - but I tried to switch to Unicode few days ago and it was failing the same way.
Edit: it's pretty much impossible to select options using arrows (will throw the error immediately) and the number keys won't work correctly too. For now I left the default options which should work.
The text was updated successfully, but these errors were encountered:
This issue is still present and has nothing to do with venv - I would rather suspect keyboard layout setting or maybe OS codepage... for now using the numbers on the keyboard work but trying to use cursor keys immediately breaks the installation.
Cauldrath
pushed a commit
to Cauldrath/kohya_ss
that referenced
this issue
Apr 5, 2023
Basically when I try to run accelerate config it will throw a bunch of errors:
(venv) PS G:!AI\SD\kohya_ss> accelerate config
------------------------------------------------------------------------------------------------------------------------In which compute environment are you running?
Please select a choice using the arrow or number keys, and selecting with enter
Traceback (most recent call last):
File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "G:!AI\SD\kohya_ss\venv\Scripts\accelerate.exe_main.py", line 7, in
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\accelerate_cli.py", line 45, in main
args.func(args)
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config.py", line 67, in config_command
config = get_user_input()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config.py", line 32, in get_user_input
compute_environment = _ask_options(
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\config\config_utils.py", line 58, in _ask_options
result = menu.run(default_choice=default)
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\selection_menu.py", line 118, in run
choice = self.handle_input()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\input.py", line 73, in handle_input
char = get_character()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\keymap.py", line 114, in get_character
char = get_raw_chars()
File "G:!AI\SD\kohya_ss\venv\lib\site-packages\accelerate\commands\menu\keymap.py", line 77, in get_raw_chars
if ch.encode(encoding) in (b"\x00", b"\xe0"):
UnicodeEncodeError: 'mbcs' codec can't encode characters in position 0--1: invalid character
I'm running Polish version of Windows and 852 (OEM - Latin II) codepage for the cmd / powershell - but I tried to switch to Unicode few days ago and it was failing the same way.
Edit: it's pretty much impossible to select options using arrows (will throw the error immediately) and the number keys won't work correctly too. For now I left the default options which should work.
The text was updated successfully, but these errors were encountered: