缺少:tensorflow.compiler.xla.service import hlo_pb2

2024-05-14 13:12:15 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在尝试构建一个TensorRT文件,以便在我的jetson nano上运行。 我正在运行tensorflow 1.13。 当我运行此代码时:

trt_graph = trt.create_inference_graph(
input_graph_def=['input_1'],
outputs=['Logits/Softmax'],
max_batch_size=1,
max_workspace_size_bytes=1 << 25,
precision_mode='FP16',
minimum_segment_size=50
)

我得到这个错误:

ImportError: cannot import name hlo_pb2

它说它在这里寻找它:

from tensorflow.compiler.xla.service import hlo_pb2

它不存在吗? 我已经更新了tensorflow。 在tensorflow.compiler.xla.service位置有'hlo_xxxxxx'个文件的分配,但没有"hlo_pb2"

有什么想法吗


Tags: 文件importinputsizecompilertensorflowservicemax

热门问题