本文整理汇总了Python中simulator.Simulator.sarsaType方法的典型用法代码示例。如果您正苦于以下问题:Python Simulator.sarsaType方法的具体用法?Python Simulator.sarsaType怎么用?Python Simulator.sarsaType使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类simulator.Simulator
的用法示例。
在下文中一共展示了Simulator.sarsaType方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: Simulator
# 需要导入模块: from simulator import Simulator [as 别名]
# 或者: from simulator.Simulator import sarsaType [as 别名]
__author__ = 'manuelli'
from simulator import Simulator
sim = Simulator(autoInitialize=False, verbose=False)
sim.sarsaType = "discrete"
sim.options['SARSA']['lam'] = 0.0
sim.options['SARSA']['useQLearningUpdate'] = True
sim.options['SARSA']['numInnerBins'] = 5
sim.options['SARSA']['numOuterBins'] = 4
sim.options['SARSA']['binCutoff'] = 0.5
sim.options['SARSA']['epsilonGreedy'] = 0.4
sim.options['SARSA']['useSupervisedTraining'] = False
sim.options['Sensor']['rayLength'] = 10
sim.options['Sensor']['numRays'] = 20
sim.options['Reward']['actionCost'] = 0.4
sim.options['Reward']['raycastCost'] = 40.0
# sim.options['Reward']['collisionPenalty'] = 200
sim.options['Car']['velocity'] = 16
sim.options['World']['obstaclesInnerFraction'] = 0.85
sim.options['dt'] = 0.05
示例2: Simulator
# 需要导入模块: from simulator import Simulator [as 别名]
# 或者: from simulator.Simulator import sarsaType [as 别名]
__author__ = 'manuelli'
from simulator import Simulator
sim = Simulator(autoInitialize=False, verbose=False)
sim.sarsaType = "continuous"
sim.Sarsa_numInnerBins = 4
sim.Sarsa_numOuterBins = 4
sim.Sensor_rayLength = 10
#
# # small world
# sim.randomSeed = 11
# sim.randomizeControl = True
# sim.percentObsDensity = 3.5
# sim.nonRandomWorld = True
# sim.circleRadius = 2.0
# sim.worldScale = 0.5
#
#
# big world
# sim.randomSeed = 10
# sim.randomizeControl = True
# sim.percentObsDensity = 3
# sim.nonRandomWorld = True
# sim.circleRadius = 2.5
# sim.worldScale = 1
# # big dense
# sim.randomSeed = 12