浏览代码

crawler: add time reward

/develop/bisim-sac-transfer
yanchaosun 4 年前
当前提交
8f8ec11b
共有 5 个文件被更改,包括 407 次插入7 次删除
  1. 4
      Project/Assets/ML-Agents/Examples/Crawler/Prefabs/Crawler.prefab
  2. 402
      Project/Assets/ML-Agents/Examples/Crawler/Scenes/CrawlerStaticTarget.unity
  3. 2
      Project/Assets/ML-Agents/Examples/Crawler/Scripts/CrawlerAgent.cs
  4. 4
      Project/Assets/ML-Agents/Examples/OldCrawler/Prefabs/OldCrawler.prefab
  5. 2
      Project/Assets/ML-Agents/Examples/OldCrawler/Scripts/OldCrawlerAgent.cs

4
Project/Assets/ML-Agents/Examples/Crawler/Prefabs/Crawler.prefab


agentParameters:
maxStep: 0
hasUpgradedFromAgentParameters: 1
MaxStep: 1000
MaxStep: 5000
maximumWalkingSpeed: 999
target: {fileID: 0}
targetSpawnRadius: 40

orientationCube: {fileID: 2270141184585723037}
rewardMovingTowardsTarget: 1
rewardFacingTarget: 1
rewardUseTimePenalty: 0
rewardUseTimePenalty: 1
useFootGroundedVisualization: 0
foot0: {fileID: 0}
foot1: {fileID: 0}

402
Project/Assets/ML-Agents/Examples/Crawler/Scenes/CrawlerStaticTarget.unity


propertyPath: m_ConnectedAnchor.z
value: 0.28284454
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

propertyPath: m_ConnectedAnchor.z
value: 0.28284454
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

propertyPath: m_ConnectedAnchor.y
value: -0.14285131
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000066310167
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000672
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.0000067949295
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000684
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.000006571412
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.3300071
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000069588423
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000648
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 1b9d167a4e71146a883212e4f08bda88, type: 3}
--- !u!1001 &471764575

propertyPath: m_ConnectedAnchor.y
value: -0.14285131
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000066310167
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000672
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.0000067949295
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000684
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.000006571412
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.3300071
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000069588423
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000648
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 1b9d167a4e71146a883212e4f08bda88, type: 3}
--- !u!1001 &586831923

propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000066310167
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000672
objectReference: {fileID: 0}
objectReference: {fileID: 11400000, guid: 2ddbe780c2a664a8db253b5eef2c21dc,
objectReference: {fileID: 11400000, guid: d4cca12958df14c21aa0766c3a8b8525,
type: 3}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.0000067949295
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000684
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.000006571412
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.3300071
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000069588423
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000648
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 1b9d167a4e71146a883212e4f08bda88, type: 3}
--- !u!1001 &680193204

type: 3}
propertyPath: m_ConnectedAnchor.y
value: -0.14285858
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000066310167
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000672
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.0000067949295
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000684
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.000006571412
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.3300071
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000069588423
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000648
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 1b9d167a4e71146a883212e4f08bda88, type: 3}

propertyPath: m_ConnectedAnchor.z
value: 0.28284454
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

propertyPath: m_ConnectedAnchor.y
value: -0.14285858
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000066310167
objectReference: {fileID: 0}
- target: {fileID: 3386028169001571294, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000672
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.0000067949295
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000684
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.000006571412
objectReference: {fileID: 0}
- target: {fileID: 3386028170881877093, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.3300071
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.0000069588423
objectReference: {fileID: 0}
- target: {fileID: 3386028170904845107, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.y
value: 0.33000648
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 1b9d167a4e71146a883212e4f08bda88, type: 3}
--- !u!1001 &2071138685

propertyPath: m_ConnectedAnchor.z
value: 0.28284454
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

propertyPath: m_ConnectedAnchor.z
value: 0.28284454
objectReference: {fileID: 0}
- target: {fileID: 3386028169665032405, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028169836750752, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

- target: {fileID: 3386028169838659253, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: 0.2828369
objectReference: {fileID: 0}
objectReference: {fileID: 0}
- target: {fileID: 3386028170461648232, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}
propertyPath: m_ConnectedAnchor.x
value: -0.2828369
objectReference: {fileID: 0}
- target: {fileID: 3386028170626051599, guid: 1b9d167a4e71146a883212e4f08bda88,
type: 3}

2
Project/Assets/ML-Agents/Examples/Crawler/Scripts/CrawlerAgent.cs


/// </summary>
void RewardFunctionTimePenalty()
{
AddReward(-0.001f);
AddReward(0.0001f);
}
/// <summary>

4
Project/Assets/ML-Agents/Examples/OldCrawler/Prefabs/OldCrawler.prefab


agentParameters:
maxStep: 0
hasUpgradedFromAgentParameters: 1
MaxStep: 1000
MaxStep: 5000
target: {fileID: 0}
ground: {fileID: 0}
detectTargets: 0

leg3Lower: {fileID: 3650911777174035777}
rewardMovingTowardsTarget: 1
rewardFacingTarget: 1
rewardUseTimePenalty: 0
rewardUseTimePenalty: 1
useFootGroundedVisualization: 0
foot0: {fileID: 0}
foot1: {fileID: 0}

2
Project/Assets/ML-Agents/Examples/OldCrawler/Scripts/OldCrawlerAgent.cs


/// </summary>
void RewardFunctionTimePenalty()
{
AddReward(-0.001f);
AddReward(0.0001f);
}
/// <summary>

正在加载...
取消
保存