添加时间步索引作为节点输入 ====================================== 时间节点是数据的时间信息。通过配置时间步节点信息,可以将时间步索引作为指定节点的输入。 下面使用一个 ``.yaml`` 示例进行时间步索引配置展示: .. code:: yaml metadata: graph: action: - observation next_observation: - action - observation columns: ... .. image:: images/step_node_1_.png :alt: step_node_1 :align: center 上面是原始的 ``.yaml`` 文件。在下面修改过后的 ``.yaml`` 文件中,我们通过添加关键字 ``step_input`` 作为节点的属性, 将时间步长信息配置为 ``next_observation`` 的输入。在训练模型的过程中, ``time_step`` 会自动添加作为 ``action`` 节点的输入。 .. code:: yaml metadata: graph: action: - observation next_observation: - action - observation columns: ... nodes: action: step_input: True .. image:: images/step_node_2_.png :alt: step_node_2 :align: center .. important:: 不需要在 ``graph`` 中添加 ``time_step`` 节点作为输入。如果配置了节点的 ``step_input`` 属性,时间步节点信息将会自动增加作为节点的输入。