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
In the Vitis AI 3.0 repository, I built the GPU Docker for TensorFlow 1.x and after launching it,
I got the following SyntaxError when running the vai_q_tensorflow command.
It was a SyntaxError and we solved it by fixing some source code, so please consider fixing it if possible.
・Error
vitis-ai-user@xxx:/workspace$ vai_q_tensorflow --help
Traceback (most recent call last):
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/bin/vai_q_tensorflow", line 7, in <module>
from vai_q_tensorflow.python.decent_q import run_main
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/vai_q_tensorflow/__init__.py", line 38, in <module>
from vai_q_tensorflow.python.decent_q import inspect
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/vai_q_tensorflow/python/decent_q.py", line 91, in <module>
from progressbar import ProgressBar
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/progressbar/__init__.py", line 3, in <module>
from .utils import (
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/progressbar/utils.py", line 9, in <module>
from python_utils.time import timedelta_to_seconds, epoch, format_time
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/python_utils/__init__.py", line 1, in <module>
from . import (
File "/opt/vitis_ai/conda/envs/vitis-ai-tensorflow/lib/python3.6/site-packages/python_utils/converters.py", line 89
if match := regexp.search(input_):
^
SyntaxError: invalid syntax
I changed “:=” to “==” in lines 89 and 170 of converters.py and the error was resolved.
・L89
87 try:
88 if regexp and input_:
89 if match == regexp.search(input_):
90 #if match := regexp.search(input_):
91 input_ = match.groups()[-1]
・L170
168 try:
169 if regexp:
170 if match == regexp.search(input_):
171 #if match := regexp.search(input_):
172 input_ = match.group(1)
・after chenged
vitis-ai-user@xxx:/workspace$ vai_q_tensorflow --help
usage:
usage: vai_q_tensorflow command [Options]
examples:
show help : vai_q_tensorflow --help
quantize a model: vai_q_tensorflow quantize --input_frozen_graph frozen_graph.pb --input_nodes xxx --output_nodes yyy --input_shapes zzz --input_fn module.calib_input
inspect a model : vai_q_tensorflow inspect --input_frozen_graph frozen_graph.pb
dump quantized model : vai_q_tensorflow dump --input_frozen_graph quantize_results/quantize_eval_model.pb --input_fn module.dump_input
update old quantized model: vai_q_tensorflow update --input_frozen_graph quantize_results/quantize_eval_model.pb
Xilinx's Quantization ToolsVai_q_tensorflow 3.0.0-dev-gpu build for Tensorflow
1.15.2 git version d2e041a
positional arguments:
{quantize,inspect,dump,deploy,update}
Specify a command for vai_q_tensorflow
optional arguments:
-h, --help show this help message and exit
--version show program's version number and exit
--mode {frozen,train,eval}
The text was updated successfully, but these errors were encountered:
Hi
In the Vitis AI 3.0 repository, I built the GPU Docker for TensorFlow 1.x and after launching it,
I got the following SyntaxError when running the vai_q_tensorflow command.
It was a SyntaxError and we solved it by fixing some source code, so please consider fixing it if possible.
・Error
I changed “:=” to “==” in lines 89 and 170 of converters.py and the error was resolved.
・L89
・L170
・after chenged
The text was updated successfully, but these errors were encountered: