Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

编码错误问题 #4

Open
aaskk opened this issue Aug 18, 2021 · 3 comments
Open

编码错误问题 #4

aaskk opened this issue Aug 18, 2021 · 3 comments

Comments

@aaskk
Copy link
Collaborator

aaskk commented Aug 18, 2021

Error executing job with overrides: []
Traceback (most recent call last):
File "D:/kk/autoML/hyperbox/hyperbox/run.py", line 31, in main
utils.print_config(config, resolve=True)
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\pytorch_lightning\utilities\distributed.py", line 48, in wrapped_fn
return fn(*args, **kwargs)
File "D:\kk\autoML\hyperbox\hyperbox\hyperbox\utils\utils.py", line 150, in print_config
rich.print(tree, file=fp)
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\rich_init_.py", line 68, in print
return write_console.print(*objects, sep=sep, end=end)
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\rich\console.py", line 1615, in print
self._buffer.extend(new_segments)
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\rich\console.py", line 825, in exit
self._exit_buffer()
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\rich\console.py", line 784, in _exit_buffer
self._check_buffer()
File "C:\Users\kk\anaconda3\envs\hydra\lib\site-packages\rich\console.py", line 1836, in _check_buffer
write(line)
UnicodeEncodeError: 'gbk' codec can't encode character '\u2699' in position 0: illegal multibyte sequence
*** You may need to add PYTHONIOENCODING=utf-8 to your environment ***

Set the environment variable HYDRA_FULL_ERROR=1 for a complete stack trace.

Process finished with exit code 1

操作系统:Windows10
8月13的版本直接运行python run.py没有此问题,8月18版本直接运行python run.py运行出现该问题。在linux下没有此问题

pprp pushed a commit that referenced this issue Oct 19, 2021
merge master of marggbo to master of pprp
@L1690941806
Copy link

I met the same problem when I ran this code:
Error executing job with overrides: ['experiment=fewshot_search_nb201.yaml', 'logger.wandb.name=fewshot_search_nb201_c10_ID_mincut_sp_16splits', '+trainer.gpus=0', '+mo
del.is_net_parallel=False', 'logger.wandb.offline=True', 'trainer.strategy=null', 'engine.split_criterion=ID', 'engine.split_method=mincut']
Traceback (most recent call last):
File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hyperbox\run.py", line 50, in
main()
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\main.py", line 90, in decorated_main
_run_hydra(
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 389, in _run_hydra
_run_app(
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 452, in _run_app
run_and_report(
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 216, in run_and_report
raise ex
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 213, in run_and_report
return func()
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 453, in
lambda: hydra.run(
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\hydra.py", line 132, in run
_ = ret.return_value
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 260, in return_value
raise self._return_value
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 186, in run_job
ret.return_value = task_function(task_cfg)
self._check_buffer()
File "D:\apps\Anaconda\envs\naslid\lib\site-packages\rich\console.py", line 2046, in _check_buffer
write("".join(batch))
UnicodeEncodeError: 'gbk' codec can't encode character '\u2699' in position 0: illegal multibyte sequence
*** You may need to add PYTHONIOENCODING=utf-8 to your environment ***
How can I solve this problem?Looking forward to your reply

@marsggbo
Copy link
Owner

I met the same problem when I ran this code: Error executing job with overrides: ['experiment=fewshot_search_nb201.yaml', 'logger.wandb.name=fewshot_search_nb201_c10_ID_mincut_sp_16splits', '+trainer.gpus=0', '+mo del.is_net_parallel=False', 'logger.wandb.offline=True', 'trainer.strategy=null', 'engine.split_criterion=ID', 'engine.split_method=mincut'] Traceback (most recent call last): File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hyperbox\run.py", line 50, in main() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\main.py", line 90, in decorated_main _run_hydra( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 389, in _run_hydra _run_app( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 452, in _run_app run_and_report( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 216, in run_and_report raise ex File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 213, in run_and_report return func() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 453, in lambda: hydra.run( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\hydra.py", line 132, in run _ = ret.return_value File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 260, in return_value raise self._return_value File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 186, in run_job ret.return_value = task_function(task_cfg) self._check_buffer() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\rich\console.py", line 2046, in _check_buffer write("".join(batch)) UnicodeEncodeError: 'gbk' codec can't encode character '\u2699' in position 0: illegal multibyte sequence *** You may need to add PYTHONIOENCODING=utf-8 to your environment *** How can I solve this problem?Looking forward to your reply

Did you use hyperbox in Windows system? We would recommend you to use it in Linux, as we did not verify it in Windows.

@L1690941806
Copy link

I met the same problem when I ran this code: Error executing job with overrides: ['experiment=fewshot_search_nb201.yaml', 'logger.wandb.name=fewshot_search_nb201_c10_ID_mincut_sp_16splits', '+trainer.gpus=0', '+mo del.is_net_parallel=False', 'logger.wandb.offline=True', 'trainer.strategy=null', 'engine.split_criterion=ID', 'engine.split_method=mincut'] Traceback (most recent call last): File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "D:\apps\Anaconda\envs\naslid\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hyperbox\run.py", line 50, in main() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\main.py", line 90, in decorated_main _run_hydra( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 389, in _run_hydra _run_app( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 452, in _run_app run_and_report( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 216, in run_and_report raise ex File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 213, in run_and_report return func() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\utils.py", line 453, in lambda: hydra.run( File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra_internal\hydra.py", line 132, in run _ = ret.return_value File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 260, in return_value raise self._return_value File "D:\apps\Anaconda\envs\naslid\lib\site-packages\hydra\core\utils.py", line 186, in run_job ret.return_value = task_function(task_cfg) self._check_buffer() File "D:\apps\Anaconda\envs\naslid\lib\site-packages\rich\console.py", line 2046, in _check_buffer write("".join(batch)) UnicodeEncodeError: 'gbk' codec can't encode character '\u2699' in position 0: illegal multibyte sequence *** You may need to add PYTHONIOENCODING=utf-8 to your environment *** How can I solve this problem?Looking forward to your reply

Did you use hyperbox in Windows system? We would recommend you to use it in Linux, as we did not verify it in Windows.

yeah,I ran in Windows. Thank you very much,I will try in linux.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants