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

yapf.yapflib.errors.YapfError: <unknown>:148:4: invalid syntax #359

Open
mixed-fish opened this issue Jun 26, 2024 · 0 comments
Open

yapf.yapflib.errors.YapfError: <unknown>:148:4: invalid syntax #359

mixed-fish opened this issue Jun 26, 2024 · 0 comments

Comments

@mixed-fish
Copy link

(swin_det) E:\s_t\Swin-Transformer-Object-Detection-master>python tools/train.py configs\swin\mask_rcnn_swin_tiny_patch4_window7_mstrain_480-800_adamw_3x_coco.py
fused_weight_gradient_mlp_cuda module not found. gradient accumulation fusion with weight gradient computation disabled.
Traceback (most recent call last):
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf\pytree\pytree_utils.py", line 113, in ParseCodeToTree
tree = parser_driver.parse_string(code, debug=False)
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf_third_party_ylib2to3\pgen2\driver.py", line 188, in parse_string
return self.parse_tokens(tokens, debug)
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf_third_party_ylib2to3\pgen2\driver.py", line 157, in parse_tokens
if p.addtoken(type, value, (prefix, start)):
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf_third_party_ylib2to3\pgen2\parse.py", line 230, in addtoken
return self._addtoken(ilabel, type, value, context)
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf_third_party_ylib2to3\pgen2\parse.py", line 313, in _addtoken
raise ParseError('bad input', type, value, context)
yapf_third_party._ylib2to3.pgen2.parse.ParseError: bad input: type=20, value='<', context=('', (148, 3))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf\yapflib\yapf_api.py", line 206, in FormatCode
tree = pytree_utils.ParseCodeToTree(unformatted_source)
File "D:\py\Anaconda3\envs\swin_det\lib\site-packages\yapf\pytree\pytree_utils.py", line 116, in ParseCodeToTree
ast.parse(code)
File "D:\py\Anaconda3\envs\swin_det\lib\ast.py", line 47, in parse
return compile(source, filename, mode, flags,
File "", line 148
os=<module 'os' from 'D:\py\Anaconda3\envs\swin_det\lib\os.py'>
^
SyntaxError: invalid syntax

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

1 participant