Search found 65 matches

by mattions
Sun May 17, 2009 7:05 am
Forum: UNIX/Linux
Topic: Neuron refuse to run if the DISPLAY is wrongly set
Replies: 3
Views: 2961

Re: Neuron refuse to run if the DISPLAY is wrongly set

Thanks.

That did the trick.

in python, to unset is also possible to run:

Code: Select all

import os
if os.environ.has_key('DISPLAY')
    del os.environ['DISPLAY']
by mattions
Wed May 13, 2009 7:48 am
Forum: UNIX/Linux
Topic: Neuron refuse to run if the DISPLAY is wrongly set
Replies: 3
Views: 2961

Neuron refuse to run if the DISPLAY is wrongly set

Hello, I want to run neuron only for a batch job, without using any DISPLAY but it seems it's not possible. I'm going to use it on a cluster where the DISPLAY will be not available. check this: $ DISPLAY="" $ ipython In [1]: import neuron can't open DISPLAY Where that message come from? Where is the...
by mattions
Wed Jan 28, 2009 8:24 am
Forum: NEURON + Python
Topic: Delete a section does not work
Replies: 14
Views: 8744

Delete a section does not work

in python seems to not be possible to delete a section

Code: Select all

from neuron import h
a = h.Section()
b = h.Section()
b.connect(a)
c = h.Section()
c.connect(a)
h.topology()
h.delete_section(c)
I've tried also:

Code: Select all

h.delete_section(c.name())
and

Code: Select all

c.push()
h.delete_section()
Any idea?
by mattions
Tue Jan 27, 2009 6:52 am
Forum: NEURON + Python
Topic: SubClassing a section
Replies: 4
Views: 2331

Re: SubClassing a section

One thing more on this I discovered that when you initiate the class in python you should use the init of the parent class (I've got a segmental fault) Actually that is the right way to do it in python... Test this code: from neuron import hclass, h import nrn class MySection(nrn.Section): def __ini...
by mattions
Mon Jan 26, 2009 1:46 am
Forum: NEURON + Python
Topic: SubClassing a section
Replies: 4
Views: 2331

SubClassing a section

I'm trying to subclass a section, but something is not working. Am I doing correctly? from neuron import hclass, h class MySection(hclass(h.Section)): def printTest(self): "Hello, I'm section %s" %self.name() a = MySection() this is the error: /usr/lib/python2.5/site-packages/neuron/__init__.pyc in ...
by mattions
Mon Jan 05, 2009 9:35 am
Forum: NEURON + Python
Topic: iPython, gtk, qt, tk
Replies: 2
Views: 2054

Re: iPython, gtk, qt, tk

It's working also with neuron 6.2.3 and IPython 0.9.1

thanks emuller.. Pretty slick :)
by mattions
Thu Nov 27, 2008 1:21 pm
Forum: NEURON + Python
Topic: Connecting a NetStim to a Synapses with a NetCon
Replies: 4
Views: 3553

Re: Connecting a NetStim to a Synapses with a NetCon

Hi Hines, thank you for the replies :) The syntax you proposed work well and I'm able to connect the two right now. The problem is the AMPA is seems to not receive any input, and I'm thinking to try to build a small test model to have at least a prototype synapse working from scratch. I would like t...
by mattions
Tue Nov 25, 2008 1:07 pm
Forum: NEURON + Python
Topic: Connecting a NetStim to a Synapses with a NetCon
Replies: 4
Views: 3553

Connecting a NetStim to a Synapses with a NetCon

Hello, I'm trying to connect this AMPA synapse (coming from the Wolf 2005 model) with a stim in python. Here is the code I'm using: #!/usr/bin/env python import neuron h = neuron.h dend = h.Section() stim = h.NetStim() AMPA = neuron.new_point_process('AMPA') ampa_syn1 = AMPA(dend, 0.5) nc = h.NetCon...
by mattions
Tue Nov 25, 2008 6:48 am
Forum: NEURON + Python
Topic: Creating sections and inserting mechanisms
Replies: 3
Views: 1678

Re: Creating sections and inserting mechanisms

More on the insert mechanism. Actually I've confused the insert a point process mechanism (like an IClamp) with the instead a diffuse mechanism (like n HH channel) The synatax proposed here is perfectly working. Sorry my bad. http://www.davison.webfactional.com/notes/modelling-single-cells-neuron-py...
by mattions
Thu Nov 20, 2008 11:33 am
Forum: NEURON + Python
Topic: Creating sections and inserting mechanisms
Replies: 3
Views: 1678

Re: Creating sections and inserting mechanisms

I found that it's possible to insert the mechanism using the section

Code: Select all

soma = h.Section()
soma.insert('MyMech')
It makes sense :)
by mattions
Thu Nov 20, 2008 8:40 am
Forum: NEURON + Python
Topic: Creating sections and inserting mechanisms
Replies: 3
Views: 1678

Creating sections and inserting mechanisms

I'm wondering if it is possible to create a section in a way it's not anonymous. for example soma = h.Section() create an anonymous section it would be cool to have something like soma = h.Section(name='soma') so when I run topology, or any other tool that display the name of the section I have a be...
by mattions
Thu Nov 20, 2008 4:34 am
Forum: NEURON + Python
Topic: the `-' in a prompt
Replies: 3
Views: 1808

Re: the `-' in a prompt

You can use ipython:

Launch it

Code: Select all

ipython

and at the prompt:

Code: Select all

In [1]: run file.py
it will execute the file and give you the prompt
by mattions
Fri Nov 07, 2008 2:59 pm
Forum: UNIX/Linux
Topic: Neuron 6.2 Fail to build on Ubuntu [SOLVED]
Replies: 0
Views: 1731

Neuron 6.2 Fail to build on Ubuntu [SOLVED]

Hi everybody, after I have patched the code according to the instructions contained in this Topic http://www.neuron.yale.edu/phpBB/viewtopic.php?f=6&t=1318 I've obtained this error: make[3]: Entering directory `/home/mattions/Work/progs/neuron/nrn-6.2/src/nrnoc' (MODLUNIT=../../share/lib/nrnunits.li...
by mattions
Fri Nov 07, 2008 12:46 pm
Forum: UNIX/Linux
Topic: IV Build Fails at OS/math.cpp on Fedora 9
Replies: 8
Views: 4200

Re: IV Build Fails at OS/math.cpp on Fedora 9

Confirm the BUG also on Ubuntu 8.10

it seems that if 4.3 is involved the package stop to build :)
by mattions
Wed Oct 01, 2008 10:57 am
Forum: NEURON + Python
Topic: iPython, gtk, qt, tk
Replies: 2
Views: 2054

iPython, gtk, qt, tk

Is there anyway to run ipython and to open a thread for interview?

Is it possible for the gtk the qt the tk so it doesn't look that bad.

Anyone has found a way and want to share? :)