是否可以训练具有 "splited" 输出的神经网络

Is it possible to train a neural network with "splited" output

是否可以将一个神经网络的输出视为两组或更多组输出?

我再解释一下(在 q 学习环境中):

Imagine i have two agents in the same environement and each agents have a different amount of performable actions. Both of the agents will have the same input vector containing environnemental variables to chose their actions.

问题是:

我可以使用独特的神经网络来控制两个代理吗?

一个例子:

Agent 1 have 3 performable actions and Agent 2 have only 2 performable actions. An important thing is that the agent will have to work cooperatively to maximize the reward. Can i use 1 neural network with 5 outputs to chose the best action to do for both agents ? like the first 3 outputs of the network will be the Q values for the first agent and the 2 others will be the Q values for agent 2. My reward function will always be based on the global results, each agents will not have specific reward.

可能吗?因为我没有找到任何关于那个的东西。 如果您需要更高的精度,请询问。

我也知道一个可能的解决方案应该是制作一个具有 3 * 2 个输出的网络,每个输出将是几个动作(每个代理一个动作),但我真的很想知道是否有人已经这样做了有人像我之前解释过的那样,或者只是如果有人知道那行不通以及为什么。

我不知道这个专门用于强化学习,但 multi-output 神经网络在文献中很常见。

如果您希望一个网络控制两个代理,共享网络的早期阶段可能是个好主意,然后再将网络分成两个不同的分支,每个分支中有几个层。

有关如何处理多个输出的示例,您可以查看 this link