在b站DDPG跟着大佬一起复现论文代码,遇到了【ValueError: Cannot feed value of shape (64,) for Tensor ‘TargetActor/inputs:0’, which has shape ‘(?, 3)’】的错误
问题描述
这个error显示是维度的错误,于是我按照网上的经验,将下面代码中的input_dim=[3]
改成了input_dim=[2]
,但是这时候又出现了这个错误:ValueError: Cannot feed value of shape (64,) for Tensor 'TargetActor/inputs:0', which has shape '(?, 2)'
的错误,从shape'(?, 3)'
变成了shape'(?, 2)'
,这就说明,不是维度的维问题,没办法,网上关于这个错误的经验贴很少,所以我就只能回放视频,看看是哪里出现错误了
if __name__ == '__main__':