浏览代码

Made a nicer comment

/develop/rm-rf-new-models
vincentpierre 4 年前
当前提交
e0cf88e6
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 4
      ml-agents/mlagents/trainers/torch/networks.py

4
ml-agents/mlagents/trainers/torch/networks.py


At this moment, torch.onnx.export() doesn't accept None as tensor to be exported,
so the size of return tuple varies with action spec.
"""
# This code will convert the ugly vec and obs into glorious unified list of inputs
# This code will convert the vec and vis obs into a list of inputs for the network
concatenated_vec_obs = vec_inputs[0]
inputs = []
start = 0

else:
inputs.append(vis_inputs[vis_index])
vis_index += 1
# End of code to convert the ugly vec and obs into glorious unified list of inputs
# End of code to convert the vec and vis obs into a list of inputs for the network
encoding, memories_out = self.network_body(
inputs, memories=memories, sequence_length=1
)

正在加载...
取消
保存