浏览代码

Make editor extensions and inference utils internal (#3390)

* make our editor extensions internal

* MLAgents.InferenceBrain.Utils too
/asymm-envs
GitHub 5 年前
当前提交
8b9dfcd7
共有 7 个文件被更改,包括 7 次插入7 次删除
  1. 2
      com.unity.ml-agents/Editor/AgentEditor.cs
  2. 2
      com.unity.ml-agents/Editor/BehaviorParametersEditor.cs
  3. 2
      com.unity.ml-agents/Editor/BrainParametersDrawer.cs
  4. 2
      com.unity.ml-agents/Editor/DemonstrationDrawer.cs
  5. 2
      com.unity.ml-agents/Editor/DemonstrationImporter.cs
  6. 2
      com.unity.ml-agents/Runtime/InferenceBrain/Utils/Multinomial.cs
  7. 2
      com.unity.ml-agents/Runtime/InferenceBrain/Utils/RandomNormal.cs

2
com.unity.ml-agents/Editor/AgentEditor.cs


*/
[CustomEditor(typeof(Agent), true)]
[CanEditMultipleObjects]
public class AgentEditor : Editor
internal class AgentEditor : Editor
{
public override void OnInspectorGUI()
{

2
com.unity.ml-agents/Editor/BehaviorParametersEditor.cs


*/
[CustomEditor(typeof(BehaviorParameters))]
[CanEditMultipleObjects]
public class BehaviorParametersEditor : Editor
internal class BehaviorParametersEditor : Editor
{
const float k_TimeBetweenModelReloads = 2f;
// Time since the last reload of the model

2
com.unity.ml-agents/Editor/BrainParametersDrawer.cs


/// Inspector.
/// </summary>
[CustomPropertyDrawer(typeof(BrainParameters))]
public class BrainParametersDrawer : PropertyDrawer
internal class BrainParametersDrawer : PropertyDrawer
{
// The height of a line in the Unity Inspectors
const float k_LineHeight = 17f;

2
com.unity.ml-agents/Editor/DemonstrationDrawer.cs


/// </summary>
[CustomEditor(typeof(Demonstration))]
[CanEditMultipleObjects]
public class DemonstrationEditor : Editor
internal class DemonstrationEditor : Editor
{
SerializedProperty m_BrainParameters;
SerializedProperty m_DemoMetaData;

2
com.unity.ml-agents/Editor/DemonstrationImporter.cs


/// Asset Importer used to parse demonstration files.
/// </summary>
[ScriptedImporter(1, new[] {"demo"})]
public class DemonstrationImporter : ScriptedImporter
internal class DemonstrationImporter : ScriptedImporter
{
const string k_IconPath = "Assets/ML-Agents/Resources/DemoIcon.png";

2
com.unity.ml-agents/Runtime/InferenceBrain/Utils/Multinomial.cs


/// entry[i] = P(x \le i), NOT P(i - 1 \le x \lt i).
/// (\le stands for less than or equal to while \lt is strictly less than).
/// </summary>
public class Multinomial
internal class Multinomial
{
readonly System.Random m_Random;

2
com.unity.ml-agents/Runtime/InferenceBrain/Utils/RandomNormal.cs


/// https://en.wikipedia.org/wiki/Marsaglia_polar_method
/// TODO: worth overriding System.Random instead of aggregating?
/// </summary>
public class RandomNormal
internal class RandomNormal
{
readonly double m_Mean;
readonly double m_Stddev;

正在加载...
取消
保存