private TextController textController; //テキストコントローラー //================================================================= //コンポーネント参照用 private void ComponentRef() { neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); manager = GameObject.Find("Manager").GetComponent <Manager>(); textController = transform.Find("TextController").GetComponent <TextController>(); }
//============================================================== //コンポーネント参照用 private void ComponentRef() { fieldManager = transform.Find("FieldManager").GetComponent <FieldManager>(); parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); actionSaver = GameObject.Find("ActionSaver").GetComponent <ActionSaver>(); soundManagerBGM = GameObject.Find("SoundManagerBGM").GetComponent <SoundManager>(); }
private void Awake() { if (s_instance != null) { Debug.Log("Warning: More than two instances of NeuralNetworkManager have been detected!"); } s_instance = this; }
private void TrainNeuralNetwork() { var builder = new ConvolutionNeuralNetworkBuilder(); var preparedDataPath = Path.Combine(neuralNetworkOptions.BaseFolder, neuralNetworkOptions.PreparedDataFile); var modelPath = Path.Combine(neuralNetworkOptions.BaseFolder, neuralNetworkOptions.ModelFile); var numClasses = Enum.GetNames(typeof(Emotion)).Length - 1; //without "no faces" status NeuralNetworkManager.TrainModel(builder, preparedDataPath, modelPath, neuralNetworkOptions.ImageWidth, numClasses); }
//================================================================ //参照用 private void ComponentRef() { cursor = transform.Find("Frame/Cursor").gameObject; frame = transform.Find("Frame").gameObject; manager = GameObject.Find("Manager").GetComponent <Manager>(); inputManager = GameObject.Find("InputManager").GetComponent <InputManager>(); parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); actionSaver = GameObject.Find("ActionSaver").GetComponent <ActionSaver>(); }
public LinkManager(int maxCreatures) { _networkManager = NetworkSettings.ActiveNetwork; _networkIDByCreatureID = new int[maxCreatures]; _creatureByNetworkID = new Creature[maxCreatures]; WorldSettings.LinkManager = this; WorldSettings.ActiveWorld.RegisterCreatureRemovedFromWorldCallback(OnCreatureDied); }
//============================================================== //参照用 private void ComponentRef() { manager = GameObject.Find("Manager").GetComponent <Manager>(); fieldManager = GameObject.Find("Manager").transform.Find("FieldManager").GetComponent <FieldManager>(); animator = transform.Find("Sprite").GetComponent <Animator>(); parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); textBox = GameObject.Find("Canvas/TextBox").GetComponent <TextBox>(); neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); soundManagerSE = GameObject.Find("SoundManagerSE").GetComponent <SoundManager>(); }
private void Start() { _activeWorld = WorldSettings.ActiveWorld; _networkManager = NetworkSettings.ActiveNetwork; AddCreatureActions(); AddCreatureSensors(); _linkManager = new LinkManager(WorldSettings.MaxCreatures); StartCoroutine("SpawnCreaturesInterval"); }
private void Start() { int maxNetworks = WorldSettings.MaxCreatures; var inputManager = new SensorManager(maxNetworks); var outputManager = new ActionManager(maxNetworks); _networkManager = new NeuralNetworkManager(maxNetworks, inputManager, outputManager); SetStaticVariables(); StartCoroutine("ProcessNetworksCoroutine"); }
//============================================================== //コンポーネント参照用 private void ComponentRef() { manager = GameObject.Find("Manager").GetComponent <Manager>(); fieldManager = GameObject.Find("Manager/FieldManager").GetComponent <FieldManager>(); parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); animator = transform.Find("Sprite").GetComponent <Animator>(); fieldMap = GameObject.Find("Canvas/FieldMap").GetComponent <FieldMap>(); textBox = GameObject.Find("Canvas/TextBox").GetComponent <TextBox>(); itemManager = GameObject.Find("Manager/FieldManager/ItemManager").GetComponent <ItemManager>(); inputManager = GameObject.Find("InputManager").GetComponent <InputManager>(); focus = GameObject.Find("Canvas/Focus").GetComponent <Focus>(); actionSaver = GameObject.Find("ActionSaver").GetComponent <ActionSaver>(); neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); soundManagerSE = GameObject.Find("SoundManagerSE").GetComponent <SoundManager>(); }
void Awake() { if (Instance == null) { Instance = this; } else { Destroy(this.gameObject); return; } GameController = GetComponent <GameController>(); NeuralNetworkManager = GetComponent <NeuralNetworkManager>(); NextFighterController = NextFighterController ?? typeof(HealOpponentFighterController); paused = true; }
private void OnEnable() { if (neuralNetwork != null) { return; } if (this.patternsFile == null) { Debug.LogWarning(this.ToString() + " cannot run neural networks without a patterns file"); return; } var network = new NeuralNetworkManager(); neuralNetwork = network.Run(this.patternsFile.text, this.iterationCount, this.networkCount, this.inputDimensions, this.hiddenDimensions, this.outputDimensions, this.trainingPercentage, this.datasetHasHeaders, this.debugLogWhenTraining, this.learnRate, this.momentum, this.targetError); }
private void Start() { // 將輪胎裡面的 Curve 給進去 curveM = this.GetComponent <CurveManager>(); for (int i = 0; i < wheels.Length; i++) { wheels[i].CurveM = curveM; } Application.targetFrameRate = 30; QualitySettings.vSyncCount = 0; // 拿東西 if (centerOfMass != null) { this.GetComponent <Rigidbody>().centerOfMass = centerOfMass.localPosition; } this.GetComponent <Rigidbody>().inertiaTensor *= inertiaFactor; drivetrain = this.GetComponent <Drivetrain>(); // 拿 NN Manager NNManger = this.GetComponent <NeuralNetworkManager>(); }
private NeuralNetworkManager neuralNetworkManager; //ニューラルネットワークマネージャー //============================================================== //コンポーネント参照用 private void ComponentRef() { parameterManager = GameObject.Find("ParameterManager").GetComponent <ParameterManager>(); text = GameObject.Find("Canvas/Text").GetComponent <Text>(); neuralNetworkManager = GameObject.Find("NeuralNetworkManager").GetComponent <NeuralNetworkManager>(); }