Small fizes

This commit is contained in:
Andrey Gumirov
2022-04-19 19:24:53 +07:00
parent 4bd1e0644a
commit aae98595d3
5 changed files with 8 additions and 6 deletions

View File

@ -1 +1 @@
{"count":1,"self":16.7881248,"total":28.869280999999997,"children":{"InitializeActuators":{"count":1,"self":0.0062039999999999994,"total":0.0062039999999999994,"children":null},"InitializeSensors":{"count":1,"self":0.009415,"total":0.009415,"children":null},"AgentInfo.ToProto":{"count":1,"self":0.0037809999999999996,"total":0.023178,"children":{"GenerateSensorData":{"count":1,"self":0.019396999999999998,"total":0.019396999999999998,"children":null}}},"AgentSendState":{"count":1094,"self":0.070126,"total":2.03434,"children":{"CollectObservations":{"count":1094,"self":1.694399,"total":1.694399,"children":null},"WriteActionMask":{"count":1094,"self":0.01526,"total":0.01526,"children":null},"RequestDecision":{"count":1094,"self":0.046751999999999995,"total":0.254555,"children":{"AgentInfo.ToProto":{"count":1094,"self":0.027583999999999997,"total":0.207803,"children":{"GenerateSensorData":{"count":1094,"self":0.180219,"total":0.180219,"children":null}}}}}}},"DecideAction":{"count":1094,"self":9.9110736,"total":9.911074,"children":null},"AgentAct":{"count":1094,"self":0.088208,"total":0.090377,"children":{"AgentInfo.ToProto":{"count":10,"self":0.00033,"total":0.002169,"children":{"GenerateSensorData":{"count":10,"self":0.001839,"total":0.001839,"children":null}}}}}},"gauges":{"npc.CumulativeReward":{"count":11,"max":0,"min":0,"runningAverage":0,"value":0,"weightedAverage":0}},"metadata":{"timer_format_version":"0.1.0","start_time_seconds":"1650283028","unity_version":"2019.4.36f1","command_line_arguments":"\/Applications\/Unity\/Hub\/Editor\/2019.4.36f1\/Unity.app\/Contents\/MacOS\/Unity -projectpath \/Users\/gav\/tmp\/projects\/real-shooter -useHub -hubIPC -cloudEnvironment production -licensingIpc LicenseClient-gav -hubSessionId 3b1d3b50-bef1-11ec-a2f1-7fead03718a2 -accessToken r8bZAeodsmy_r-5SjXH5Fv1-VHYleg9acf27P9OS5KU009f","communication_protocol_version":"1.5.0","com.unity.ml-agents_version":"2.0.1","scene_name":"Greatest_map_ever","end_time_seconds":"1650283056"}} {"count":1,"self":253.933696,"total":298.669542,"children":{"InitializeActuators":{"count":1,"self":0.005415,"total":0.005415,"children":null},"InitializeSensors":{"count":1,"self":0.008598,"total":0.008598,"children":null},"AgentInfo.ToProto":{"count":1,"self":0.0036699999999999997,"total":0.021755999999999998,"children":{"GenerateSensorData":{"count":1,"self":0.018085999999999998,"total":0.018085999999999998,"children":null}}},"AgentSendState":{"count":6944,"self":0.233448,"total":1.314088,"children":{"CollectObservations":{"count":6944,"self":0.32020899999999997,"total":0.32020899999999997,"children":null},"WriteActionMask":{"count":6944,"self":0.051706999999999996,"total":0.051706999999999996,"children":null},"RequestDecision":{"count":6944,"self":0.135635,"total":0.708724,"children":{"AgentInfo.ToProto":{"count":6944,"self":0.088769,"total":0.573089,"children":{"GenerateSensorData":{"count":6944,"self":0.48432,"total":0.48432,"children":null}}}}}}},"DecideAction":{"count":6944,"self":43.1909152,"total":43.190914,"children":null},"AgentAct":{"count":6944,"self":0.183273,"total":0.18875699999999998,"children":{"AgentInfo.ToProto":{"count":69,"self":0.000744,"total":0.005484,"children":{"GenerateSensorData":{"count":69,"self":0.0047399999999999994,"total":0.0047399999999999994,"children":null}}}}}},"gauges":{"npc.CumulativeReward":{"count":70,"max":0,"min":0,"runningAverage":0,"value":0,"weightedAverage":0}},"metadata":{"timer_format_version":"0.1.0","start_time_seconds":"1650370738","unity_version":"2019.4.36f1","command_line_arguments":"\/Applications\/Unity\/Hub\/Editor\/2019.4.36f1\/Unity.app\/Contents\/MacOS\/Unity -projectpath \/Users\/gav\/tmp\/projects\/real-shooter -useHub -hubIPC -cloudEnvironment production -licensingIpc LicenseClient-gav -hubSessionId 6cd92410-bfd2-11ec-8ee1-a9a435d1c35b -accessToken 8rpFnsCAS7iPqYsIEudq2a-EfGjvYCbkRj1LbKfo7EM009f","communication_protocol_version":"1.5.0","com.unity.ml-agents_version":"2.0.1","scene_name":"Greatest_map_ever","end_time_seconds":"1650371036"}}

View File

@ -1122,7 +1122,7 @@ Transform:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 705507993} m_GameObject: {fileID: 705507993}
m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261}
m_LocalPosition: {x: 77.5, y: 55.2, z: -5.9} m_LocalPosition: {x: 81.2, y: 64.1, z: -12.4}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: [] m_Children: []
m_Father: {fileID: 0} m_Father: {fileID: 0}
@ -2600,7 +2600,7 @@ Transform:
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2060099471} m_GameObject: {fileID: 2060099471}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 19.553204, y: 7.782543, z: -15} m_LocalPosition: {x: 27.79, y: 7.782543, z: -15}
m_LocalScale: {x: 1, y: 1, z: 1} m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: m_Children:
- {fileID: 1345085341} - {fileID: 1345085341}

View File

@ -31,7 +31,7 @@ public class MovementController : MonoBehaviour
public void MoveToRandomPoint() public void MoveToRandomPoint()
{ {
Debug.Log(MapManager.navPoints == null); // Debug.Log(MapManager.navPoints == null);
goToNextNavPoint(MapManager.navPoints[Random.Range(0, MapManager.navPoints.Count)]); goToNextNavPoint(MapManager.navPoints[Random.Range(0, MapManager.navPoints.Count)]);
} }

View File

@ -74,8 +74,8 @@ public class NPC : Agent, ICharacter
? 1 ? 1
: 0 : 0
}; };
var _parray = string.Join(" ", parray); // var _parray = string.Join(" ", parray);
Debug.Log("OBS: " + _parray); // Debug.Log("OBS: " + _parray);
bufferSensor.AppendObservation(parray); bufferSensor.AppendObservation(parray);
} }
} }

View File

@ -60,9 +60,11 @@ public class GameManager : MonoBehaviour
{ {
case Team.Attackers: case Team.Attackers:
Debug.Log("Attackers Win"); Debug.Log("Attackers Win");
ResetScene();
break; break;
case Team.Defenders: case Team.Defenders:
Debug.Log("Defenders Win"); Debug.Log("Defenders Win");
ResetScene();
break; break;
default: default:
Debug.LogError("Unexpected Team"); Debug.LogError("Unexpected Team");