Neuropixels data - Electrode (X,Y,Z)

Hello,
I am looking at the .nwb files provided for the visual coding observatory. The file contains information about each “electrode” or “probe” on the neuropixel, including its “id” and “local_index” along with the horizontal and vertical_position. Recently, it looks like the x,y,z positions were added to this, based on the CCFv3 framework, as mentioned in the Technical white paper. But in the files I have looked at (eg 778230327) the y and z position are identical. I can imagine that if the shank was implanted at 45 degrees, this would be fine, but I assume that not all shanks were implanted at 45 degrees. Am I correct to assume that these x,y,z correspond to the position in brain co-ordinates? Or I am misinterpreting what these variables mean.
Thanks,
Chinmay

1 Like

Hi Chinmay,

The Y positions were accidentally duplicated when generating those NWB files. This is a known issue, which is being tracked here.

As far as I know, there’s no specific timeline for getting this fixed, but fortunately the correct coordinates are available in the channels.csv that’s accessible via the AllenSDK. If you follow this notebook through cell 7, it will download a file that contains the coordinates for each electrode, indexed by id. The left_right_ccf_coordinate column contains the same information that should be in the z position in the NWB file.

Hi Josh,
This did work out well for me, by using the channels.csv file. Thanks for your help !
Chinmay

Hi Josh

Odd question: When plotting electrode XYZ positions for a single probe (i.e.773462985) with CCF coordinates taken from channels.csv I was expecting to get a straight line that corresponds to electrodes located along a straight probe. Instead I see a strongly bended one. Is it a result of a CCF curving procedure or the probe was bended ( and correspondingly registered as such)?

Yuri

That’s right – we first fit the probe trajectories in the original, unwarped brain, where they are very straight. We then perform an independent registration procedure in which we align the original brain to the CCF template using hand-annotated keypoints. When the original probe trajectory is warped into CCF space, it becomes curved.