Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Is it possible to gain access to each neuron in all the layers trough the Python API?

Discussion in 'ML-Agents' started by bornacvitanic, Jul 20, 2021.

  1. bornacvitanic

    bornacvitanic

    Joined:
    Feb 28, 2017
    Posts:
    10
    I'm new to ML, and was wondering if it is possible to acces the data from each hidden layer each step as it is possible to acces all the observation and action data.
     
  2. andrewcoh_unity

    andrewcoh_unity

    Unity Technologies

    Joined:
    Sep 5, 2019
    Posts:
    162
    Hi @bornacvitanic

    Do you mean you'd like to access the weights/biases of the network layers of the policy/value function during training?
     
  3. bornacvitanic

    bornacvitanic

    Joined:
    Feb 28, 2017
    Posts:
    10
    @andrewcoh_unity I would like to visualize the network while it is training. I am giving the network a 64x64 grid sensor as input, which I am able to visualize as an image trough the python API from the observations array. I would like to do that for each layer to see how it interprets the inputs and which neurons fire. So i guess I would need acess to each neurons weights/biases.