problem of importing asc file

Managing anatomically complex model cells with the CellBuilder. Importing morphometric data with NEURON's Import3D tool or Robert Cannon's CVAPP. Where to find detailed morphometric data.
Post Reply
yemy

problem of importing asc file

Post by yemy »

I have an asc format morphology file to be imported to Neuron. It has a "cellbody" comprised of 54 z stack created in NLucida. The asc codes look fine, but the file failed to be imported into Neuron with Import3D tool. I had tried to reduce cellbody contour to 1 stack. The problem still exists. Only when the cell body is defined as a point with a specific diameter(see below codes), the entire morphology can be loaded by Neuron. But this is not what a real soma looks like.

Could you please let me know where is the problem? and how to fix it? Thank you very much!

Code: Select all

("CellBody"
  (Color RGB (255, 128, 0))
  (CellBody)
  (  352.34   188.14    77.00    30.13)  ;  1, 1
 )  ;  End of contour





Problem Codes start:
-------------------------------------------------------------------------------------------------------------------------

Code: Select all

;
;	V3 text file written for MicroBrightField products.
(ImageCoords Filename "C:\09_s2c1_neuron.tif" Merge 65535 65535 65535 0
 Coords 0.5 0.5 0 0 0 0.5 0.5 0 0 -0.5 0.5 0.5 0 0 -1 0.5 0.5 0 0 -1.5 0.5
 0.5 0 0 -2 0.5 0.5 0 0 -2.5 0.5 0.5 0 0 -3 0.5 0.5 0 0 -3.5 0.5 0.5 0 0 -4
 0.5 0.5 0 0 -4.5 0.5 0.5 0 0 -5 0.5 0.5 0 0 -5.5 0.5 0.5 0 0 -6 0.5 0.5 0 0
 -6.5 0.5 0.5 0 0 -7 0.5 0.5 0 0 -7.5 0.5 0.5 0 0 -8 0.5 0.5 0 0 -8.5 0.5 0.5
 0 0 -9 0.5 0.5 0 0 -9.5 0.5 0.5 0 0 -10 0.5 0.5 0 0 -10.5 0.5 0.5 0 0 -11
 0.5 0.5 0 0 -11.5 0.5 0.5 0 0 -12 0.5 0.5 0 0 -12.5 0.5 0.5 0 0 -13 0.5 0.5
 0 0 -13.5 0.5 0.5 0 0 -14 0.5 0.5 0 0 -14.5 0.5 0.5 0 0 -15 0.5 0.5 0 0
 -15.5 0.5 0.5 0 0 -16 0.5 0.5 0 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79.5 0.5 0.5 0 0 -80 0.5 0.5 0 0 -80.5 0.5 0.5 0 0 -81 0.5 0.5 0 0
 -81.5 0.5 0.5 0 0 -82 0.5 0.5 0 0 -82.5 0.5 0.5 0 0 -83 0.5 0.5 0 0 -83.5
 0.5 0.5 0 0 -84 0.5 0.5 0 0 -84.5 0.5 0.5 0 0 -85 0.5 0.5 0 0 -85.5 0.5 0.5
 0 0 -86 0.5 0.5 0 0 -86.5 0.5 0.5 0 0 -87 0.5 0.5 0 0 -87.5 0.5 0.5 0 0 -88
 0.5 0.5 0 0 -88.5 0.5 0.5 0 0 -89 0.5 0.5 0 0 -89.5 0.5 0.5 0 0 -90 0.5 0.5
 0 0 -90.5 0.5 0.5 0 0 -91 0.5 0.5 0 0 -91.5 0.5 0.5 0 0 -92 0.5 0.5 0 0
 -92.5 0.5 0.5 0 0 -93 0.5 0.5 0 0 -93.5 0.5 0.5 0 0 -94 0.5 0.5 0 0 -94.5
) ; End of ImageCoords

("Cell Body"
  (Color Magenta)
  (CellBody)
  (  348.00  -189.50   -64.50     0.50)  ;  1, 1
  (  348.50  -189.00   -64.50     0.50)  ;  1, 2
  (  348.50  -188.50   -64.50     0.50)  ;  1, 3
  (  350.00  -187.00   -64.50     0.50)  ;  1, 4
  (  350.50  -187.00   -64.50     0.50)  ;  1, 5
  (  351.00  -186.50   -64.50     0.50)  ;  1, 6
  (  353.00  -186.50   -64.50     0.50)  ;  1, 7
  (  353.50  -187.00   -64.50     0.50)  ;  1, 8
  (  354.00  -187.00   -64.50     0.50)  ;  1, 9
  (  355.00  -188.00   -64.50     0.50)  ;  1, 10
  (  355.00  -188.50   -64.50     0.50)  ;  1, 11
  (  355.50  -189.00   -64.50     0.50)  ;  1, 12
  (  355.50  -191.00   -64.50     0.50)  ;  1, 13
  (  355.00  -191.50   -64.50     0.50)  ;  1, 14
  (  355.00  -192.00   -64.50     0.50)  ;  1, 15
  (  353.50  -193.50   -64.50     0.50)  ;  1, 16
  (  353.00  -193.50   -64.50     0.50)  ;  1, 17
  (  352.50  -194.00   -64.50     0.50)  ;  1, 18
  (  350.50  -194.00   -64.50     0.50)  ;  1, 19
  (  350.00  -193.50   -64.50     0.50)  ;  1, 20
  (  349.50  -193.50   -64.50     0.50)  ;  1, 21
  (  348.50  -192.50   -64.50     0.50)  ;  1, 22
  (  348.50  -192.00   -64.50     0.50)  ;  1, 23
  (  348.00  -191.50   -64.50     0.50)  ;  1, 24
)  ;  End of contour

("Cell Body"
  (Color Magenta)
  (CellBody)
  (  347.50  -189.00   -65.00     0.50)  ;  2, 1
  (  348.00  -188.50   -65.00     0.50)  ;  2, 2
  (  348.00  -188.00   -65.00     0.50)  ;  2, 3
  (  349.00  -187.00   -65.00     0.50)  ;  2, 4
  (  349.00  -186.50   -65.00     0.50)  ;  2, 5
  (  350.00  -185.50   -65.00     0.50)  ;  2, 6
  (  350.50  -185.50   -65.00     0.50)  ;  2, 7
  (  351.00  -185.00   -65.00     0.50)  ;  2, 8
  (  353.00  -185.00   -65.00     0.50)  ;  2, 9
  (  353.50  -185.50   -65.00     0.50)  ;  2, 10
  (  354.00  -185.50   -65.00     0.50)  ;  2, 11
  (  355.00  -186.50   -65.00     0.50)  ;  2, 12
  (  355.00  -187.00   -65.00     0.50)  ;  2, 13
  (  355.50  -187.50   -65.00     0.50)  ;  2, 14
  (  355.50  -188.00   -65.00     0.50)  ;  2, 15
  (  356.00  -188.50   -65.00     0.50)  ;  2, 16
  (  356.00  -190.50   -65.00     0.50)  ;  2, 17
  (  355.50  -191.00   -65.00     0.50)  ;  2, 18
  (  355.50  -191.50   -65.00     0.50)  ;  2, 19
  (  355.00  -192.00   -65.00     0.50)  ;  2, 20
  (  355.00  -192.50   -65.00     0.50)  ;  2, 21
  (  353.50  -194.00   -65.00     0.50)  ;  2, 22
  (  353.00  -194.00   -65.00     0.50)  ;  2, 23
  (  352.50  -194.50   -65.00     0.50)  ;  2, 24
  (  350.50  -194.50   -65.00     0.50)  ;  2, 25
  (  350.00  -194.00   -65.00     0.50)  ;  2, 26
  (  349.50  -194.00   -65.00     0.50)  ;  2, 27
  (  348.50  -193.00   -65.00     0.50)  ;  2, 28
  (  348.50  -192.50   -65.00     0.50)  ;  2, 29
  (  348.00  -192.00   -65.00     0.50)  ;  2, 30
  (  348.00  -191.50   -65.00     0.50)  ;  2, 31
  (  347.50  -191.00   -65.00     0.50)  ;  2, 32
)  ;  End of contour

....
...
...
..

ted
Site Admin
Posts: 6300
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: problem of importing asc file

Post by ted »

To answer your questions, we will need two things:
First, what version of NEURON are you using? (what is the first line that NEURON prints to the terminal when it starts)
Second, please zip up the morphology file and email it to ted dot carnevale at yale dot edu
yemy

Re: problem of importing asc file

Post by yemy »

I have email you with a brief morphology file.

I use Neuron7.1 to import morphology.
The console states " 4133 lines read". But, soma sections are lost and invisible.

When I export it to cellbuilder, the console pops up two cellbuilder windows. The morphology is invisible in topology menu.
ted
Site Admin
Posts: 6300
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: problem of importing asc file

Post by ted »

The problem is in the NeuroLucida file. Lines like

Code: Select all

("Cell Body"
are supposed to read

Code: Select all

("CellBody"
without the space.

You could fix the problem by making a copy of the file, then opening the copy in a text editor and changing every instance of

Code: Select all

Cell Body
to

Code: Select all

CellBody
If you have many files with this problem, you might prefer to change the Import3D tool instead.
Open nrn/lib/hoc/import3d/read_nlcda3.hoc in a text editor and change

Code: Select all

          if (strcmp(current.s, "CellBody") == 0) { keep = 1 }
to

Code: Select all

          if (strcmp(current.s, "CellBody") == 0) { keep = 1 }
          if (strcmp(current.s, "Cell Body") == 0) { keep = 1 }
See line 924 of the file.
yemy

Re: problem of importing asc file

Post by yemy »

Now the morphology with multiple z stacks of soma can be displayed in import3d GUI. But each main processes were connected to the center point of soma outlines, which is apparently not the real case. When exported to Cellbuilder, the morphology were not shown. Seems that neuron morphology with multi z stacks of soma is not well compatible with NEURON. If it is exported to hoc file, we can find that soma section is not described as mutilple stacks.

Could you please reexamine the file I sent you previously? Thank you very much!
ted
Site Admin
Posts: 6300
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: problem of importing asc file

Post by ted »

yemy wrote:each main processes were connected to the center point of soma outlines
True. That's the Import3D tool's policy. The result is a model that produces simulations that do not differ significantly from what you'd get if the proximal ends of those branches were attached to the "surface" of the soma.
When exported to Cellbuilder, the morphology were not shown.
Because the xyz coordinates of the morphometric data lie outside the viewport of the CellBuilder's shape plot. Use that shape plot's "View = plot" and you'll see the CellBuilder's simplified representation of the cell. To see a detailed shape plot, first make sure that a model cell exists (click on the CellBuilder's "Continuous create" button), then click on
Neuron Main Menu / Graph / Shape plot
It may be necessary to use "View = plot" to center the image.
Seems that neuron morphology with multi z stacks of soma is not well compatible with NEURON.
False.
If it is exported to hoc file, we can find that soma section is not described as mutilple stacks.
True, because there is no computational advantage in doing that. The soma is represented as a single section, the surface area and volume of which will be a close approximation to the volume of the shape defined by the stack of outlines.

"An approximation? The properties of the model soma will deviate from the highly precise morphometric reconstruction?"

Yes, it is an approximation, but compared to other approximations it doesn't amount to a hill of beans. Soma surface area and volume are extremely small compared to the total surface area and volume of most neurons. All measurements in any morphometric data file are approximations, especially diameter measurements, particularly when diameters are on the order of 1-2 microns where 0.1 um errors in diameter measurement mean a 10-20% error in cross sectional area and volume. In many cell classes, more than half of the surface area of the cell is in neurites with diameters < 2 um, so 0.1 um variance in diameter measurement introduces far more error than any approximation about the size and shape of the soma. For most cell classes, you could probably leave out the soma completely without affecting the behavior of the model cell. Furthermore, aside from a few special cases (e.g. myelinated optic nerve axons), neurites do not have a circular cross-section, yet diameter measurements are always treated as if they are circular. That's a big approximation. And I haven't even raised any histological issues--tissue shrinkage, amputation of neurites, blurring caused by light scatter, completeness of fill, difficulty resolving cell boundaries in thin neurites especially when stains like HRP are used--or instrumentation limitations (all morphometric reconstruction systems have a minimum diameter quantization increment, which is typically much larger than 0.1 um so it isn't even possible to record diameters of thin neurites to within 0.1 um of their actual values).

And what about biophysical properties? There's at least 10% uncertainty about the the biophysical properties of different kinds of ion channels. Very little or nothing is known about how channel density varies over the surface of most classes of neurons. Almost nothing is known about whether the densities of different ionic channels are independent of each other, or whether they covary (Golowasch et al. 2002 suggests there is at least some covariance). Forget about ion channels--who even knows the actual value of specific membrane capacitance--is it 0.8, 1.2, 2.5 uf/cm2, or is it different from cell to cell? And what about cytoplasmic resistivity, which is extremely difficult to determine?

So a little sense of proportion is necessary when judging what approximations may be acceptable and what approximations may be fatal. And maybe it would be a good idea to reconsider whether the time and effort that is invested in tracing out the surface of the soma in great detail is worth it.
yemy

Re: problem of importing asc file

Post by yemy »

hi,Ted,

Thank you for your detail explanation on Neuron approximation strategy. I originally expected multi stacks of soma would be treated as an array of sections or a section with multiple segments. An element of the array or a segment of soma section might correspond to a typical stack of traced soma and be presented as a cylinder with diameter of a traced soma stack outline and height of z stack distance.

So, with your answers, now I will be confidently dealing with the morphology for simulation in current version.

In light of Neuron's approximation about soma, a comment is that: it might possibly be better to divide soma into several segments(maybe nseg=3-5) so as to connect different soma compartments with different main processes. After all, the main processes are not directly electric-coupled. How do you think about it? Also, I would be happy to examine if this kind of segmentation makes any significant difference?

Many thanks again!
Post Reply