SyntaxError:语法无效-冒号?

时间:2019-12-25 23:15:47

标签: python python-3.x

我正在尝试在python 3.7上运行muzero代码,但出现以下错误:

...
from networks.network import BaseNetwork, UniformNetwork

KnownBounds = collections.namedtuple('KnownBounds', ['min', 'max'])


class MuZeroConfig(object):

def __init__(self,
             game,
             nb_training_loop: int,
             nb_episodes: int,
             nb_epochs: int,
             network_args: Dict,
             network,
             action_space_size: int,
             max_moves: int,
             discount: float,
             dirichlet_alpha: float,
             num_simulations: int,
             batch_size: int,
             td_steps: int,
             visit_softmax_temperature_fn,
             lr: float,
             known_bounds: Optional[KnownBounds] = None):
    ### Environment
    self.game = game

    ### Self-Play
    self.action_space_size = action_space_size
    # self.num_actors = num_actors
    ...

错误...第18行

    nb_training_loop: int,
                    ^
SyntaxError: invalid syntax

但是我相信可以在这里放一个冒号。如何调试此问题?

0 个答案:

没有答案