Skip to content

Commit

Permalink
Merge ebe697a into 0d822e8
Browse files Browse the repository at this point in the history
  • Loading branch information
espenhgn committed Jul 11, 2019
2 parents 0d822e8 + ebe697a commit cfafa9f
Show file tree
Hide file tree
Showing 11 changed files with 66 additions and 65 deletions.
5 changes: 4 additions & 1 deletion .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
conda:
file: doc/environment.yml
python:
setup_py_install: true
version: 3.6
setup_py_install: true
requirements_file: doc/requirements.txt
system_packages: false
2 changes: 1 addition & 1 deletion LFPy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
* run_simulations - Functions to run NEURON simulations
"""

__version__ = "2.0.2"
__version__ = "2.0.3"

from .pointprocess import Synapse, PointProcess, StimIntElectrode
from .recextelectrode import RecExtElectrode, RecMEAElectrode
Expand Down
4 changes: 2 additions & 2 deletions LFPy/cell.py
Original file line number Diff line number Diff line change
Expand Up @@ -2129,8 +2129,7 @@ def insert_v_ext(self, v_ext, t_ext):
return

def get_axial_currents_from_vmem(self, timepoints=None):
"""
Compute axial currents from cell sim: get current magnitude,
"""Compute axial currents from cell sim: get current magnitude,
distance vectors and position vectors.
Parameters
Expand Down Expand Up @@ -2159,6 +2158,7 @@ def get_axial_currents_from_vmem(self, timepoints=None):
the mid point of each axial current in i_axial in units of (µm). The
indices of the first axis, correspond to the first axis
of i_axial and d_vectors.
Raises
------
AttributeError
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ This scientific software is released under the GNU Public License GPLv3.

Code status
===========
[![PyPI version](https://badge.fury.io/py/LFPy.svg)](https://badge.fury.io/py/LFPy)
[![Build Status](https://travis-ci.org/LFPy/LFPy.svg?branch=master)](https://travis-ci.org/LFPy/LFPy)
[![Coverage Status](https://coveralls.io/repos/github/LFPy/LFPy/badge.svg?branch=master)](https://coveralls.io/github/LFPy/LFPy?branch=master)
[![Documentation Status](https://readthedocs.org/projects/lfpy/badge/?version=latest)](http://lfpy.readthedocs.io/en/latest/?badge=latest)
Expand Down Expand Up @@ -109,9 +110,9 @@ There are few options to install LFPy:
5. Anaconda Python (macos/linux):

conda install lfpy neuron=*=mpi* # installs LFPy and Neuron in the current conda environment

or

conda create -n lfpy lfpy neuron=*=mpi* # creates new conda environment with LFPy and Neuron

Uninstall
Expand Down
9 changes: 4 additions & 5 deletions doc/classes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Module :mod:`LFPy`
:members:
:show-inheritance:
:undoc-members:

class :class:`NetworkCell`
===========================
.. autoclass:: NetworkCell
Expand Down Expand Up @@ -74,7 +74,7 @@ Module :mod:`LFPy`
:members:
:show-inheritance:
:undoc-members:

class :class:`OneSphereVolumeConductor`
=======================================
.. autoclass:: OneSphereVolumeConductor
Expand Down Expand Up @@ -105,16 +105,15 @@ Module :mod:`LFPy`
.. automodule:: LFPy.lfpcalc
:members:
:undoc-members:

submodule :mod:`tools`
======================
.. automodule:: LFPy.tools
:members:
:undoc-members:

submodule :mod:`inputgenerators`
================================
.. automodule:: LFPy.inputgenerators
:members:
:undoc-members:

5 changes: 3 additions & 2 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.doctest',
extensions = ['sphinx.ext.autodoc',
'sphinx.ext.doctest',
'sphinx.ext.autosummary',
'sphinx.ext.viewcode',
'sphinx.ext.mathjax',
Expand Down Expand Up @@ -54,7 +55,7 @@
# The short X.Y version.
version = '2.0'
# The full version, including alpha/beta/rc tags.
release = '2.0.2'
release = '2.0.3'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
3 changes: 1 addition & 2 deletions doc/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,5 @@ dependencies:
- mpi4py
- numpydoc
- sphinx
- sphinx_rtd_theme
- neuron
- pip:
- sphinx-rtd-theme
17 changes: 6 additions & 11 deletions doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,17 +56,12 @@ This scientific software is released under the GNU Public License `GPLv3 <http:/
Tutorial slides on LFPy
-----------------------

Slides for OCNS 2018 meeting tutorial `T5: Modeling and analysis of extracellular potentials <https://www.cnsorg.org/cns-2018-tutorials#T5>`_ hosted in Seattle, USA on LFPy: `CNS2018_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2018_LFPy_tutorial.pdf>`_

Slides for OCNS 2017 meeting tutorial `T4: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2017-tutorials#t4>`_ hosted in Antwerp, Belgium on LFPy and hybridLFPy: `CNS2017_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2017_LFPy_tutorial.pdf>`_

Slides from OCNS 2015 meeting tutorial `T2: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2015-tutorials#t2>`_ hosted in Prague, Czech Republic on LFPy and hybridLFPy: `CNS2015_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2015_LFPy_tutorial.pdf>`_

Slides from OCNS 2014 meeting tutorial `T4: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2014-tutorials#T4>`_ hosted in Quebec City: `hybridlfpy_tutorial_OCNS2014.pdf <http://LFPy.github.io/downloads/hybridlfpy_tutorial_OCNS2014.pdf>`_

As part of the OCNS 2013 meeting workshop `Modeling and interpretation of extracellular potentials <http://www.cnsorg.org/cns-2013-tutorials#extracellular_potentials>`_,
there was also a talk on LFPy.
The slides can be found here: `lfpy-tutorial_OCNS2013.pdf <http://LFPy.github.io/downloads/lfpy-tutorial_OCNS2013.pdf>`_.
- Slides for OCNS 2018 meeting tutorial `T5: Modeling and analysis of extracellular potentials <https://www.cnsorg.org/cns-2018-tutorials#T5>`_ hosted in Seattle, USA on LFPy: `CNS2018_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2018_LFPy_tutorial.pdf>`_
- Slides for OCNS 2017 meeting tutorial `T4: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2017-tutorials#t4>`_ hosted in Antwerp, Belgium on LFPy and hybridLFPy: `CNS2017_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2017_LFPy_tutorial.pdf>`_
- Slides from OCNS 2015 meeting tutorial `T2: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2015-tutorials#t2>`_ hosted in Prague, Czech Republic on LFPy and hybridLFPy: `CNS2015_LFPy_tutorial.pdf <http://LFPy.github.io/downloads/CNS2015_LFPy_tutorial.pdf>`_
- Slides from OCNS 2014 meeting tutorial `T4: Modeling and analysis of extracellular potentials <http://www.cnsorg.org/cns-2014-tutorials#T4>`_ hosted in Quebec City: `hybridlfpy_tutorial_OCNS2014.pdf <http://LFPy.github.io/downloads/hybridlfpy_tutorial_OCNS2014.pdf>`_
- As part of the OCNS 2013 meeting workshop `Modeling and interpretation of extracellular potentials <http://www.cnsorg.org/cns-2013-tutorials#extracellular_potentials>`_,
there was also a talk on LFPy. The slides can be found here: `lfpy-tutorial_OCNS2013.pdf <http://LFPy.github.io/downloads/lfpy-tutorial_OCNS2013.pdf>`_.


Related projects
Expand Down
2 changes: 1 addition & 1 deletion doc/information.rst
Original file line number Diff line number Diff line change
Expand Up @@ -419,7 +419,7 @@ Windows 10 Pro/Education (64-bit) install instructions:

git clone https://github.com/LFPy/LFPy.git

10. Build LFPy from source (without moving files)
10. Build LFPy from source (without moving files)
::

python setup.py develop
Expand Down
1 change: 1 addition & 0 deletions doc/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
numpy>=1.8.2
numpydoc
sphinx
sphinx-rtd-theme
78 changes: 40 additions & 38 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,26 @@
try:
import numpy
from Cython.Distutils import build_ext
cmdclass = { 'build_ext' : build_ext}
ext_modules = [
Extension('LFPy.run_simulation',
[os.path.join('LFPy', 'run_simulation.pyx')],
include_dirs=[numpy.get_include()]),
Extension('LFPy.alias_method',
[os.path.join('LFPy', 'alias_method.pyx')],
include_dirs=[numpy.get_include()]),
]
except ImportError as ie:
cmdclass = {'build_ext': build_ext}
ext_modules = [Extension('LFPy.run_simulation',
[os.path.join('LFPy', 'run_simulation.pyx')],
include_dirs=[numpy.get_include()]),
Extension('LFPy.alias_method',
[os.path.join('LFPy', 'alias_method.pyx')],
include_dirs=[numpy.get_include()]),
]
except ImportError:
print("'from Cython.Distutils import build_ext' or 'import numpy' failed!")
print("Cython extensions will not be compiled, and")
print("simulations in LFPy may run slower")
cmdclass = {}
ext_modules = []

#try and locate the nrnivmodl script of NEURON in PATH so that the
#NEURON extension file LFPy/sinsyn.mod can be compiled in place and be copied
#as part of the package_data, allowing unit tests to run
# try and locate the nrnivmodl script of NEURON in PATH so that the
# NEURON extension file LFPy/sinsyn.mod can be compiled in place and be copied
# as part of the package_data, allowing unit tests to run
from distutils.spawn import find_executable, spawn
if not any(arg in sys.argv for arg in ['sdist', 'upload']):
if not any(arg in sys.argv for arg in ['sdist', 'upload']):
if find_executable('nrnivmodl') is not None:
os.chdir(os.path.join('LFPy', 'test'))
for path in ['x86_64', 'i686', 'powerpc']:
Expand All @@ -43,33 +42,33 @@
spawn([find_executable('nrnivmodl')])
os.chdir(os.path.join('..', '..'))
else:
print("nrnivmodl script not found in PATH, thus NEURON .mod files could" +
"not be compiled, and LFPy.test() functions will fail")
print("nrnivmodl script not found in PATH, thus NEURON .mod files" +
"could not be compiled, and LFPy.test() functions will fail")

with open('README.md') as file:
long_description = file.read()

setup(
name = "LFPy",
version = "2.0.2",
maintainer = "Espen Hagen",
maintainer_email = 'espen.hagen@fys.uio.no',
packages = ['LFPy'],
package_data = {'LFPy' : [os.path.join('test', '*.hoc'),
os.path.join('test', '*.py'),
os.path.join('test', 'sinsyn.mod'),
os.path.join('i686', '*'),
os.path.join('i686', '.libs', '*'),
os.path.join('x86_64', '*'),
os.path.join('x86_64', '.libs', '*'),
os.path.join('powerpc', '*'),
os.path.join('powerpc', '.libs', '*'),
]},
name="LFPy",
version="2.0.3",
maintainer="Espen Hagen",
maintainer_email='espen.hagen@fys.uio.no',
packages=['LFPy'],
package_data={'LFPy': [os.path.join('test', '*.hoc'),
os.path.join('test', '*.py'),
os.path.join('test', 'sinsyn.mod'),
os.path.join('i686', '*'),
os.path.join('i686', '.libs', '*'),
os.path.join('x86_64', '*'),
os.path.join('x86_64', '.libs', '*'),
os.path.join('powerpc', '*'),
os.path.join('powerpc', '.libs', '*'),
]},
include_package_data=True,
cmdclass = cmdclass,
ext_modules = ext_modules,
cmdclass=cmdclass,
ext_modules=ext_modules,
url='http://LFPy.readthedocs.io',
download_url = 'https://github.com/LFPy/LFPy/tarball/v2.0.2',
download_url='https://github.com/LFPy/LFPy/tarball/v2.0.3',
license='LICENSE',
description='A module for modeling extracellular potentials of multicompartment neuron models built on NEURON',
long_description=long_description,
Expand All @@ -80,6 +79,7 @@
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Cython',
'Operating System :: OS Independent',
'Topic :: Scientific/Engineering',
Expand All @@ -89,14 +89,16 @@
'Intended Audience :: Science/Research',
'Development Status :: 5 - Production/Stable',
],
install_requires = [
install_requires=[
'numpy>=1.8',
'scipy>=0.14',
'Cython>=0.20',
'h5py>=2.5',
'mpi4py>=1.2',
],
extras_require = {'tests': ['pytest']},
dependency_links = [],
provides = ['LFPy'],
extras_require={'tests': ['pytest'],
'docs': ['sphinx', 'numpydoc', 'sphinx_rtd_theme']
},
dependency_links=[],
provides=['LFPy'],
)

0 comments on commit cfafa9f

Please sign in to comment.