Monitoring Neuron in the NRP


#1

Hi everyone! I wan to know if we can see the neurons values in the NRP. For example, does it exist any way to show in the screen v_reset, tau_m, membrane potential, etc. of every neuron? I want to watch these variables and I don’t know how to do it. Does anyone know it?


#2

Dear Juan,

About reading the membrane potential and other values out of a neuron, you may find this post useful: Acces neuron parameters in TF.
Regarding the visualization of these values, there is no such thing at the moment. Still, you can create an image containing your plots and display it in the browser (open the generic image viewer from the toolbar) by publishing this image as a ROS topic of type sensor_msgs.msg.Image (see for instance the experiments using the Dynamic Vision Sensor).

Best regards,
Luc


#3

Hi Juan,

yes, you can access the neural network module that you defined as your brain script. The NRP loads that module and makes it available in the global variable nrp.config.brain_root. You can query that in a Transfer Function and display it in the client logger or dump it in a csv file.

For the parameters such as v_reset, these are displayed in the population view inside the Transfer Functions editor.

Lastly, you have the brain visualizer as Luc already mentioned.

Best,

Georg


#4

Thanks both of you for the replay,

I have seen the post that Luc have said me and I have one problem.

The code of my TF is:

> import hbp_nrp_cle.tf_framework as nrp

> @nrp.Neuron2Robot()
> def print_membrane_potential(t):
>     clientLogger.info(nrp.config.brain_root.MossyFiber.get_data().segments[0])
>     return True

and I have the next error:
“field data must be of type str (runtime)”

I haven’t found the error in my code. Does someone know what this error is due to?


#5

Hi Juan!

clientLogger.info works only with arguments of type string.

Have you tried to convert your variable to a string before passing it to clientLogger.info?

e.g. clientLogger.info(str(nrp.config.brain_root.MossyFiber.get_data().segments[0])).


#6

Thanks @ualbanes, this was the problem. Now, the console log works fine.


#7

Happy it helped.

Btw, keep in mind that the latest version of clientLogger performs the conversion automatically;
so, after having the platform updated, you don’t need that fix.