* Initial Commit
* attempt at refactor
* Put all static methods into the CoreInternalBrain
* improvements
* more testing
* modifications
* renamed epsilon
* misc
* Now supports discrete actions
* added discrete support and RNN and visual. Left to do is refactor and save variables into models
* code cleaning
* made a tensor generator and applier
* fix on the models.py file
* Moved the Checks to a different Class
* Added some unit tests
* BugFix
* Need to generate the output tensors as well as inputs before executing the graph
* Made NodeNames static and created a new namespace
* Added comments to the TensorAppliers
* Started adding comments on the TensorGenerators code
* Added comments for the Tensor Generator
* Moving the helper classes into a separate folder
* Added initial comments to the TensorChecks
* Renamed NodeNames -> TensorNames
* Removing warnings in tests
* Now using Aut...
* Switched default Mac GFX API to Metal
* Added Barracuda pre-0.1.5
* Added basic integration with Barracuda Inference Engine
* Use predefined outputs the same way as for TF engine
* Fixed discrete action + LSTM support
* Switch Unity Mac Editor to Metal GFX API
* Fixed null model handling
* All examples converted to support Barracuda
* Added model conversion from Tensorflow to Barracuda
copied the barracuda.py file to ml-agents/mlagents/trainers
copied the tensorflow_to_barracuda.py file to ml-agents/mlagents/trainers
modified the tensorflow_to_barracuda.py file so it could be called from mlagents
modified ml-agents/mlagents/trainers/policy.py to convert the tf models to barracuda compatible .bytes file
* Added missing iOS BLAS plugin
* Added forgotten prefab changes
* Removed GLCore GFX backend for Mac, because it doesn't support Compute shaders
* Exposed GPU support for LearningBrain inference
...
* Ticked API :
- Ticked API for pypi for mlagents
- Ticked API for pypi for unity-gym
- Ticked Communication number for API
- Ticked Model Loader number for API
* Ticked the API for the pytest
* Garbage collection optimisations:
- Changed a few IEnumerable instances to IReadOnlyList. This avoids some unnecessary GC allocs that cast the Lists to IEnumerables.
- Moved cdf allocation outside of the loop to avoid unnecessary GC allocation.
- Changed GeneratorImpl to use plain float and int arrays instead of Array during generation. This avoids SetValue performing boxing on the arrays, which eliminates an awful lot of GC allocs.
* Convert InferenceBrain to use IReadOnlyList to avoid garbage creation.
Bringing bucket of temp memory allocation optimizations:
* switched to Barracuda backed tensor across the board, helps to leverage allocators and reuse of the internal buffers
* added Barracuda 0.2.4 release, which bring another set of temp memory allocation fixes
Only cosmetic and readability improvements. No functional changes were intended.
Utilities.cs
- Fixed comments across file
- Made class static
- Removed unnecessary imports
- Removed unused method arguments
- Renamed variables as appropriate to make usage clearer
- In AddRangeNoAlloc, disabled (by comment) Rider’s suggestion to revert to use of built-in Range field (Fixed)
- In TextureToTensorProxy, swapped order of first two arguments to be more in-line with convention of input, output
UtilitiesTests.cs
- Removed unnecessary imports
- Simplified array creation commands
GeneratorImp.cs
- Rider automatically deleted spaces on empty lines
- Changed call to TextureToTensorProxy to mirror new argument ordering
* Clean-up to UnityAgentsException.cs
- Removed unnecessary imports
- Fixed comment warning
- Fixed method header
* Improvements to Startup.cs
- Created const for SCENE_NAME field
- Fixed strin...
- Push (almost) all references to protobuf objects into the RpcCommunicator.
- Simplify the passing around of Agents and Agent Infos.
- Delete all references to the Batcher.
- Simplify the Environment Step by removing all of the reset and message counting logic.
- Finishes MLA-27 and MLA-28
* Created the model runner and uses a shared interface with the communicator.
Fixing bugs with dealocation
Removing unnecessary code
Added code comments
Renaming
* Addressing comments
* Modified the constructor of ModelRunner
* Addressing comments
* remaming the _verbose variable
* Addressing comments : Removed the Verbose check in the LearningBrainEditor
* ISensor and SensorBase
* camera and rendertex first pass
* use isensors for visual obs
* Update gridworld with CameraSensors
* compressed obs for reals
* Remove AgentInfo.visualObservations
* better separation of train and inference sensor calls
* compressed obs proto - need CI to generate code
* int32
* get proto name right
* run protoc locally for new fiels
* apply generated proto patch (pyi files were weird)
* don't repeat bytes
* hook up compressedobs
* dont send BrainParameters until there's an AgentInfo
* python BrainParameters now needs an AgentInfo to create
* remove last (I hope) dependency on camerares
* remove CameraResolutions and AgentInfo.visual_observations
* update mypy-protobuf version
* cleanup todos
* python cleanup
* more unit test fixes
* more unit test fix
* camera sensors for VisualFood collector, record demo
* SensorCompon...
* 1 to 1 Brain to Agent
This is a work in progess
In this PR :
- Deleted all Brain Objects
- Moved the BrainParameters into the Agent
- Gave the Agent a Heuristic method (see Balance Ball for example)
- Modified the Communicator and ModelRunner : Put can only take one agent at a time
- Made the IBrain Interface with RequestDecision and DecideAction method
No changes made to Python
[Design Doc](https://docs.google.com/document/d/1hBhBxZ9lepGF4H6fc6Hu6AW7UwOmnyX3trmgI3HpOmo/edit#)
* Removing editorconfig
* Updating BallanceBall scene
* grammar mistake
* Clearing the Agents of the Model runner
* Added Documentation on IBrain
* Modified comments on GiveModel
* Introduced a factory
* Split Learning Brain in two
* Changes to walljump
* Fixing the Unit tests
* Renaming the Brain to Policy
* Heuristic now has priority over training
* Edited code comments
* Fixing bugs
* Develop one to one scene edits...
* Initial commit removing memories from C# and deprecating memory fields in proto
* initial changes to Python
* Adding functionalities
* Fixes
* adding the memories to the dictionary
* Fixing bugs
* tweeks
* Resolving bugs
* Recreating the proto
* Addressing comments
* Passing by reference does not work. Do not merge
* Fixing huge bug in Inference
* Applying patches
* fixing tests
* Addressing comments
* Renaming variable to reflect type
* test
* WIP VectorSensor and StackedSensor
* fix a few dumb mistakes
* more VectorSensor
* remove Update(), add util methods, hook into TensorGenerator
* WriteApdater to write to tensors and arrays
* write float observations
* used circular buffer for stacked obs
* cleanup
* fix unit tests
* docstrings
* undo accidental checkins
* rider suggestions, add range check
* bounds check before writing
* undo ProjectVersion.txt change
* fix unit tests
* unit test for VectorSensor
* StackingSensor tests
* missing meta file
* missing meta file
* WriteAdapter tests
* Modifying the .proto files
* attempt 1 at refactoring Python
* works for ppo hallway
* changing the documentation
* now works with both sac and ppo both training and inference
* Ned to fix the tests
* TODOs :
- Fix the demonstration recorder
- Fix the demonstration loader
- verify the intrinsic reward signals work
- Fix the tests on Python
- Fix the C# tests
* Regenerating the protos
* fix proto typo
* protos and modifying the C# demo recorder
* modified the demo loader
* Demos are loading
* IMPORTANT : THESE ARE THE FILES USED FOR CONVERSION FROM OLD TO NEW FORMAT
* Modified all the demo files
* Fixing all the tests
* fixing ci
* addressing comments
* removing reference to memories in the ll-api
* Removed Barracuda as drop-in library, added Barracuda package dependency
* Removed Google Protobuf library as now it comes with Barracuda package
* List<T>.Length seems to be extension, which is not available in .NET coming with Unity 2017, switched to .Count
* pass shape to WriteAdapter
* handle floats on python side
* cleanup
* whitespace
* rename GetFloatObservationShape, support uncompressed in RenderTexture sensor
* numpy float32
* remove unused using
* Float sensor and unit test
* replace asserts with exceptions, docstrings
* initial commit
* Fixed the compilation errors
* fixing the tests
* Addressing the comment about the brain parameters
* Fixing typo
* Made timers more accurate
* addressing comments
* Better memory allocation
* Added some docstrings
* Adding better sensor validation
* Wrapped in #if DEBUG and also wrapped GenerateSensorData in a timer
* Timer changes
* Made the Agent reset immediately
* fixing the C# tests
* Fixing the tests still
* Trying with incremental episode ids
* deleting buffer rather than using an empty list
* Addressing the comments
* Forgot to edit the comment on AgentInfo
* Updating the migrating doc
* Fixed an obvious bug
* cleaning after an agent is done in agent processor
* Fixing the pytest errors
* Making some fields and properties internal
* Fixing the formating
* Making more things internal
* Adressing the comments
* reverting the changes made to the recorder
* WriteAdapter public
* Have to make AgentInfo and TensorProxy public because of changes to write adapter and the demorecorder
* Add the VectorSensor to the CollectObservation call
* Example of API change for BalanceBall
* Modified the Examples
* Changes to the migrating doc
* Editing the docs
* Update docs/Learning-Environment-Design-Agents.md
Co-Authored-By: Chris Elion <chris.elion@unity3d.com>
* Update docs/Migrating.md
Co-Authored-By: Chris Elion <chris.elion@unity3d.com>
* Update docs/Migrating.md
Co-Authored-By: Chris Elion <chris.elion@unity3d.com>
* Update docs/Getting-Started-with-Balance-Ball.md
Co-Authored-By: Chris Elion <chris.elion@unity3d.com>
* addressing comments
* Removed the MLAgents.Sensor namespace
* Removing the MLAgents.Sensor namespace from the tests
* Editing the migrating docs
Co-authored-by: Chris Elion <celion@gmail.com>
* Fix package validation errors in ISensor and CameraSensor.
* Fix docs in CameraSensor and add a helper method.
* Fix package validation errors in CameraSensorComponent.
* Fix package validation errors in SensorComponent.
* Additonal fixes to ISensor.
* Fixes package validation errors for the remaining sensor-based classses.
* Fixed docs based on PR comments. Only doc-changes.
* Fold back docs that were deleted due to merge conflict. (Was easier to delete and re-add.)
* More missing docs.
* Fixed incorrect location for doc strings.
* Adding periods at the end of param/return tags.
* Added a few periods.
* Initial test code commit
* Fix typo
* Added more tests
* More tests
* Bumping test coverage
* Update com.unity.ml-agents/Tests/Editor/ModelRunnerTest.cs
Co-Authored-By: Chris Elion <chris.elion@unity3d.com>
Co-authored-by: Chris Elion <celion@gmail.com>
* Added the MLAgents.Demonstrations namespace
* Added the MLAgents.Editor namespace
* Overrided the .demo.meta files due to the change in namespace
* More namespace changes
* Added the sidechannels namespace
* Modified changelog and migrating docs
* Update Dockerfile
* Separate send environment data from reset (#4128)
* Fixed a typo on ML-Agents-Overview.md (#4130)
Fixed redundant "to" word from the sentence since it is probably a typo in document.
* Updated the badge’s link to point to the newest doc version
* Replaced all of the doc to release_3_doc
* Fix 3DBall and 3DBallHard SAC regressions (#4132)
* Move memory validation to settings
* Update docs
* Add settings test
* Update to release_3 in installation.md (#4144)
* rename to SideChannelManager +backcompat (#4137)
* Remove comment about logo with --help (#4148)
* [bugfix] Make FoodCollector heuristic playable (#4147)
* Make FoodCollector heuristic playable
* Update changelog
* script to check for old release links and references (#4153)
* Remove package validation suite from Project (#4146)
* RayPerceptionSensor: handle empty and invalid tags (#4155...
* Add hybrid action capability flag (#4576)
* Change BrainParametersProto to support ActionSpec (#4579)
* Assign new BrainParametersProto fields based on capabilities (#4581)
* ActionBuffer with hybrid actions for RemotePolicy (#4592)
* Barracuda inference for hybrid actions (#4611)
* Refactor BarracudaModel loader checks (#4629)
* Export separate nodes for continuous/discrete actions (#4655)
* Separate continuous/discrete actions in AgentActionProto (#4698)
* Force different nodes for new and deprecated action output (#4705)
* Make modelCheck have flavors of error messages
* ONNX exporter v3
* Using a better CheckType and a switch statement
* Removing unused message
* More tests
* Use an enum for valid versions and use GetVersion on model directly
* Maybe the model export version a static constant in Python
* Use static constructor for FailedCheck
* Use static constructor for FailedCheck
* Modifying the docstrings
* renaming LegacyDiscreteActionOutputApplier
* removing testing code
* better warning message
* Nest the CheckTypeEnum into the FailedCheck class
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
* Adding a line explaining that legacy tensor checks are for versions 1.X only
* Modifying the changelog
* Exporting all the branches size instead of omly the sum (#5092)
* addressing comments
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
Co-authored...
* Make modelCheck have flavors of error messages
* ONNX exporter v3
* Using a better CheckType and a switch statement
* Removing unused message
* More tests
* Use an enum for valid versions and use GetVersion on model directly
* Maybe the model export version a static constant in Python
* Use static constructor for FailedCheck
* Use static constructor for FailedCheck
* Modifying the docstrings
* renaming LegacyDiscreteActionOutputApplier
* removing testing code
* better warning message
* Nest the CheckTypeEnum into the FailedCheck class
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
* Adding a line explaining that legacy tensor checks are for versions 1.X only
* Modifying the changelog
* Exporting all the branches size instead of omly the sum (#5092)
* addressing comments
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
Co-authored-by: Chris Elion <chris.elion@unity3d.co...
* Make modelCheck have flavors of error messages
* ONNX exporter v3
* Using a better CheckType and a switch statement
* Removing unused message
* More tests
* Use an enum for valid versions and use GetVersion on model directly
* Maybe the model export version a static constant in Python
* Use static constructor for FailedCheck
* Use static constructor for FailedCheck
* Modifying the docstrings
* renaming LegacyDiscreteActionOutputApplier
* removing testing code
* better warning message
* Nest the CheckTypeEnum into the FailedCheck class
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
* Adding a line explaining that legacy tensor checks are for versions 1.X only
* Modifying the changelog
* Exporting all the branches size instead of omly the sum (#5092)
* addressing comments
* Update com.unity.ml-agents/Runtime/Inference/BarracudaModelParamLoader.cs
Co-authored...
* Initial commit
* making it work with hallway. Added a new model version
* addressing feedback
* Adding a comment
* formatting
* modifying the changelog
* Adding descriptions on the model version descriptions
* Update com.unity.ml-agents/Runtime/Inference/GeneratorImpl.cs
Co-authored-by: Chris Elion <chris.elion@unity3d.com>
* addressing comments
Co-authored-by: Chris Elion <chris.elion@unity3d.com>
* LSTM models from 1.x will be incompatible with MLA 2.x
* Adding a test and a new v2 model
* Make the Model Runner raise an error if using 1.0 model with LSTM
* adding a new model for hallway trained with 2.0
* reword error messages
* Only raise if error, not if warning
* Addressing comments: The legacy Barrauda memory generator and applier were removed. All code that checked for (memories + v1.X) have been removed since these will no longer be supported
* Modifying the changelog and the migrating guide with this change
* Fixing the merge issues
Co-authored-by: Chris Elion <chris.elion@unity3d.com>