...
 
Commits (115)
...@@ -20,6 +20,7 @@ noinst_HEADERS = \ ...@@ -20,6 +20,7 @@ noinst_HEADERS = \
./src/libbiosiglite/biosig4c++/biosig2.h \ ./src/libbiosiglite/biosig4c++/biosig2.h \
./src/libbiosiglite/biosig4c++/biosig-dev.h \ ./src/libbiosiglite/biosig4c++/biosig-dev.h \
./src/libbiosiglite/biosig4c++/biosig-network.h \ ./src/libbiosiglite/biosig4c++/biosig-network.h \
./src/libbiosiglite/biosig4c++/config.h \
./src/libbiosiglite/biosig4c++/gdftime.h \ ./src/libbiosiglite/biosig4c++/gdftime.h \
./src/libbiosiglite/biosig4c++/mdc_ecg_codes.h \ ./src/libbiosiglite/biosig4c++/mdc_ecg_codes.h \
./src/libbiosiglite/biosig4c++/physicalunits.h \ ./src/libbiosiglite/biosig4c++/physicalunits.h \
...@@ -184,8 +185,8 @@ EXTRA_DIST+= ./dist/debian/control ...@@ -184,8 +185,8 @@ EXTRA_DIST+= ./dist/debian/control
EXTRA_DIST+= ./dist/debian/copyright EXTRA_DIST+= ./dist/debian/copyright
EXTRA_DIST+= ./dist/debian/docs EXTRA_DIST+= ./dist/debian/docs
EXTRA_DIST+= ./dist/debian/mkdeb.sh EXTRA_DIST+= ./dist/debian/mkdeb.sh
EXTRA_DIST+= ./dist/debian/python-stfio.files EXTRA_DIST+= ./dist/debian/python3-stfio.files
EXTRA_DIST+= ./dist/debian/python-stfio.install EXTRA_DIST+= ./dist/debian/python3-stfio.install
EXTRA_DIST+= ./dist/debian/rules EXTRA_DIST+= ./dist/debian/rules
EXTRA_DIST+= ./dist/debian/stimfit.1 EXTRA_DIST+= ./dist/debian/stimfit.1
EXTRA_DIST+= ./dist/debian/stimfit.desktop EXTRA_DIST+= ./dist/debian/stimfit.desktop
...@@ -205,7 +206,7 @@ EXTRA_DIST+= ./src/test/gtest/src/gtest-test-part.cc ...@@ -205,7 +206,7 @@ EXTRA_DIST+= ./src/test/gtest/src/gtest-test-part.cc
EXTRA_DIST+= ./src/test/gtest/src/gtest-typed-test.cc EXTRA_DIST+= ./src/test/gtest/src/gtest-typed-test.cc
if BUILD_PYTHON if BUILD_PYTHON
PYTHON_ADDINCLUDES = $(LIBPYTHON_INCLUDES) PYTHON_ADDINCLUDES = $(LIBPYTHON_INCLUDES) $(LIBWXPYTHON_INCLUDES)
PYTHON_ADDLDFLAGS = $(LIBPYTHON_LDFLAGS) PYTHON_ADDLDFLAGS = $(LIBPYTHON_LDFLAGS)
PYTHON_ADDLIBS = ./src/stimfit/py/libpystf.la PYTHON_ADDLIBS = ./src/stimfit/py/libpystf.la
else !BUILD_PYTHON else !BUILD_PYTHON
......
...@@ -111,6 +111,9 @@ SOURCES = ./src/stimfit/stf.cpp \ ...@@ -111,6 +111,9 @@ SOURCES = ./src/stimfit/stf.cpp \
./src/libstfio/section.cpp \ ./src/libstfio/section.cpp \
./src/libstfio/recording.cpp \ ./src/libstfio/recording.cpp \
./src/libstfio/hdf5/hdf5lib.cpp \ ./src/libstfio/hdf5/hdf5lib.cpp \
./src/libstfio/intan/intanlib.cpp \
./src/libstfio/intan/common.cpp \
./src/libstfio/intan/streams.cpp \
./src/libstfio/channel.cpp \ ./src/libstfio/channel.cpp \
./src/libstfio/stfio.cpp \ ./src/libstfio/stfio.cpp \
./src/libstfio/igor/WriteWave.c \ ./src/libstfio/igor/WriteWave.c \
...@@ -208,16 +211,21 @@ endif ...@@ -208,16 +211,21 @@ endif
CC ?= $(shell $(WXCONF) --cc) CC ?= $(shell $(WXCONF) --cc)
CXX ?= $(shell $(WXCONF) --cxx) CXX ?= $(shell $(WXCONF) --cxx)
CFLAGS = $(DEFINES) $(shell $(WXCONF) --cflags) -fstack-protector -O2 CFLAGS = $(DEFINES) $(shell $(WXCONF) --cflags) -fstack-protector -O2
CPPFLAGS = $(DEFINES) $(shell $(WXCONF) --cppflags) -std=gnu++11 -fstack-protector -O2 CPPFLAGS = $(DEFINES) $(shell $(WXCONF) --cppflags) -std=gnu++17 -fstack-protector -O2
CXXFLAGS = $(DEFINES) $(shell $(WXCONF) --cxxflags) -std=gnu++11 -fstack-protector -O2 CXXFLAGS = $(DEFINES) $(shell $(WXCONF) --cxxflags) -std=gnu++17 -fstack-protector -O2
LIBS += $(shell $(WXCONF) --libs net,adv,aui,core,base) LIBS += $(shell $(WXCONF) --libs net,adv,aui,core,base)
PREFIX ?= /usr
PKGCONF ?= $(CROSS)pkg-config
ifeq (5,$(shell $(CXX) -v 2>&1 | awk '/gcc version / {print substr($$3,1,1)}' ))
# g++-5 changes default ABI, if WX was compiled with an earlier compiler prefix ?= $(PREFIX)
CXXFLAGS += -fabi-version=2 exec_prefix = ${prefix}
endif datarootdir = ${prefix}/share
datadir = ${datarootdir}
libdir = ${exec_prefix}/lib
includedir = ${prefix}/include
bindir = ${exec_prefix}/bin
mandir = ${datarootdir}/man
PKGCONF ?= $(CROSS)pkg-config
CPPFLAGS += -I$(WXDIR) CPPFLAGS += -I$(WXDIR)
...@@ -228,17 +236,17 @@ ifneq ($(CROSS),) ...@@ -228,17 +236,17 @@ ifneq ($(CROSS),)
else else
ifneq ($(wildcard /usr/lib/libhdf5*),) ifneq ($(wildcard /usr/lib/libhdf5*),)
## Debian/Wheezy ## Debian/Wheezy
CPPFLAGS += -I$(PREFIX)/include CPPFLAGS += -I$(includedir)
LIBS += -lhdf5_hl -lhdf5 LIBS += -lhdf5_hl -lhdf5
else ifneq ($(wildcard $(PREFIX)/$(TARGET)/lib/libhdf5*),) else ifneq ($(wildcard $(prefix)/$(TARGET)/lib/libhdf5*),)
CPPFLAGS += -I$(PREFIX)/$(TARGET)/include CPPFLAGS += -I$(prefix)/$(TARGET)/include
CXXFLAGS += -I$(PREFIX)/$(TARGET)/include CXXFLAGS += -I$(prefix)/$(TARGET)/include
LDFLAGS += -L$(PREFIX)/$(TARGET)/lib LDFLAGS += -L$(prefix)/$(TARGET)/lib
LIBS += -lhdf5_hl -lhdf5 LIBS += -lhdf5_hl -lhdf5
else ifneq ($(wildcard $(PREFIX)/lib/libhdf5*),) else ifneq ($(wildcard $(libdir)/libhdf5*),)
CPPFLAGS += -I$(PREFIX)/include CPPFLAGS += -I$(includedir)
CXXFLAGS += -I$(PREFIX)/include CXXFLAGS += -I$(includedir)
LDFLAGS += -L$(PREFIX)/lib LDFLAGS += -L$(libdir)
LIBS += -lhdf5_hl -lhdf5 LIBS += -lhdf5_hl -lhdf5
else else
PLATFORM = $(shell dpkg-architecture -q DEB_TARGET_MULTIARCH) PLATFORM = $(shell dpkg-architecture -q DEB_TARGET_MULTIARCH)
...@@ -247,13 +255,15 @@ else ...@@ -247,13 +255,15 @@ else
CPPFLAGS += -I/usr/include/hdf5/serial CPPFLAGS += -I/usr/include/hdf5/serial
LDFLAGS += -L/usr/lib/$(PLATFORM) LDFLAGS += -L/usr/lib/$(PLATFORM)
LIBS += -lhdf5_serial_hl -lhdf5_serial LIBS += -lhdf5_serial_hl -lhdf5_serial
endif else
LIBS += -lhdf5_hl -lhdf5 -lz
endif
endif endif
endif endif
## BIOSIG related stuff ## ## BIOSIG related stuff ##
ifneq (,$(findstring WITH_BIOSIG2, $(DEFINES))) ifneq (,$(findstring WITH_BIOSIG2, $(DEFINES)))
LIBS += -lbiosig2 LIBS += -lbiosig
else else
ifneq (,$(findstring WITH_BIOSIG, $(DEFINES))) ifneq (,$(findstring WITH_BIOSIG, $(DEFINES)))
LIBS += -lbiosig LIBS += -lbiosig
...@@ -268,8 +278,8 @@ LIBS += -lfftw3 ...@@ -268,8 +278,8 @@ LIBS += -lfftw3
ifeq (mingw,$(findstring mingw, $(WXCONF))) ifeq (mingw,$(findstring mingw, $(WXCONF)))
LIBS += -lgfortran -lquadmath LIBS += -lgfortran -lquadmath
LIBS += -liberty -liconv
endif endif
LIBS += -ltinyxml -lstdc++
############################################################## ##############################################################
...@@ -302,8 +312,8 @@ clean: ...@@ -302,8 +312,8 @@ clean:
rm -f stimfit rm -f stimfit
install: $(TARGET) install: $(TARGET)
install $(TARGET) $(PREFIX)/bin/ install $(TARGET) $(bindir)
uninstall: uninstall:
rm $(PREFIX)/bin/stimfit rm $(bindir)/stimfit
...@@ -14,14 +14,19 @@ Guzman SJ, Schlögl A, Schmidt-Hieber C (2014) Stimfit: quantifying electrophysi ...@@ -14,14 +14,19 @@ Guzman SJ, Schlögl A, Schmidt-Hieber C (2014) Stimfit: quantifying electrophysi
## Installation ## Installation
####Windows#### #### Windows
The Windows version, including the python-stfio module, is available [here](https://github.com/neurodroid/stimfit/releases). The Windows version, including the python-stfio module, is available [here](https://github.com/neurodroid/stimfit/releases).
####OS X####
#### OS X
Stimfit for OS X is available through [MacPorts](http://www.macports.org). After [installation of MacPorts](https://www.macports.org/install.php), run Stimfit for OS X is available through [MacPorts](http://www.macports.org). After [installation of MacPorts](https://www.macports.org/install.php), run
``` ```
$ sudo port install stimfit py27-stfio $ sudo port install stimfit py27-stfio
``` ```
####GNU/Linux####
#### GNU/Linux
On Debian and Ubuntu systems, you can get Stimfit and the stfio module from the standard repositories: On Debian and Ubuntu systems, you can get Stimfit and the stfio module from the standard repositories:
``` ```
$ sudo apt-get install stimfit python-stfio $ sudo apt-get install stimfit python-stfio
......
AC_INIT([stimfit],[0.15.4]) AC_INIT([stimfit],[0.16.0])
AC_CONFIG_SRCDIR(src/stimfit/gui/main.cpp) AC_CONFIG_SRCDIR(src/stimfit/gui/main.cpp)
AM_INIT_AUTOMAKE([1.11]) AM_INIT_AUTOMAKE([1.11])
AM_SILENT_RULES([yes]) AM_SILENT_RULES([yes])
...@@ -57,7 +57,7 @@ AC_ARG_ENABLE([python], ...@@ -57,7 +57,7 @@ AC_ARG_ENABLE([python],
AM_CONDITIONAL(BUILD_PYTHON, test "$enable_python" = "yes") AM_CONDITIONAL(BUILD_PYTHON, test "$enable_python" = "yes")
if (test "$enable_python" = "yes") || (test "$enable_module" = "yes"); then if (test "$enable_python" = "yes") || (test "$enable_module" = "yes"); then
AC_PYTHON_DEVEL AC_PYTHON_DEVEL()
AC_PROG_SWIG(1.3.17) AC_PROG_SWIG(1.3.17)
SWIG_ENABLE_CXX SWIG_ENABLE_CXX
SWIG_PYTHON SWIG_PYTHON
...@@ -67,14 +67,17 @@ if (test "$enable_python" = "yes") || (test "$enable_module" = "yes"); then ...@@ -67,14 +67,17 @@ if (test "$enable_python" = "yes") || (test "$enable_module" = "yes"); then
LIBPYTHON_LDFLAGS=$PYTHON_LDFLAGS LIBPYTHON_LDFLAGS=$PYTHON_LDFLAGS
LIBPYTHON_INCLUDES=$PYTHON_CPPFLAGS LIBPYTHON_INCLUDES=$PYTHON_CPPFLAGS
LIBNUMPY_INCLUDES=$PYTHON_NUMPY_INCLUDE LIBNUMPY_INCLUDES=$PYTHON_NUMPY_INCLUDE
LIBWXPYTHON_INCLUDES=$PYTHON_WXPYTHON_INCLUDE
else else
LIBPYTHON_LDFLAGS= LIBPYTHON_LDFLAGS=
LIBPYTHON_INCLUDES= LIBPYTHON_INCLUDES=
LIBNUMPY_INCLUDES= LIBNUMPY_INCLUDES=
LIBWXPYTHON_INCLUDES=
fi fi
AC_SUBST(LIBPYTHON_LDFLAGS) AC_SUBST(LIBPYTHON_LDFLAGS)
AC_SUBST(LIBPYTHON_INCLUDES) AC_SUBST(LIBPYTHON_INCLUDES)
AC_SUBST(LIBNUMPY_INCLUDES) AC_SUBST(LIBNUMPY_INCLUDES)
AC_SUBST(LIBWXPYTHON_INCLUDES)
AC_MSG_CHECKING(for kernel) AC_MSG_CHECKING(for kernel)
case ${STFKERNEL} in case ${STFKERNEL} in
...@@ -136,10 +139,10 @@ if test "$with_pslope" = "yes" ; then ...@@ -136,10 +139,10 @@ if test "$with_pslope" = "yes" ; then
CPPFLAGS="${CPPFLAGS} -DWITH_PSLOPE" CPPFLAGS="${CPPFLAGS} -DWITH_PSLOPE"
fi fi
AC_ARG_WITH([biosig], AS_HELP_STRING([--with-biosig],[build with libbiosig support - better tested than --with-biosig2]),[]) AC_ARG_WITH([biosig], AS_HELP_STRING([--with-biosig],[build with libbiosig support]),[])
AM_CONDITIONAL(WITH_BIOSIG, test "$with_biosig" = "yes") AM_CONDITIONAL(WITH_BIOSIG, test "$with_biosig" = "yes")
AC_ARG_WITH([biosig2], AS_HELP_STRING([--with-biosig2],[alternative to --with-biosig - eventually, this will provide better ABI compatibility when upgrading libbiosig; currently it's in a testing state; requires libbiosig2 v1.5.6 or higher]),[]) AC_ARG_WITH([biosig2], AS_HELP_STRING([--with-biosig2],[equivalent to --with-biosig]),[])
AM_CONDITIONAL(WITH_BIOSIG2, test "$with_biosig2" = "yes") AM_CONDITIONAL(WITH_BIOSIG2, test "$with_biosig2" = "yes")
AC_ARG_WITH([biosiglite], AS_HELP_STRING([--with-biosiglite], [use builtin biosig library]), []) AC_ARG_WITH([biosiglite], AS_HELP_STRING([--with-biosiglite], [use builtin biosig library]), [])
...@@ -147,7 +150,7 @@ AM_CONDITIONAL(WITH_BIOSIGLITE, test "$with_biosiglite" = "yes") ...@@ -147,7 +150,7 @@ AM_CONDITIONAL(WITH_BIOSIGLITE, test "$with_biosiglite" = "yes")
if test "$with_biosig2" = "yes" ; then if test "$with_biosig2" = "yes" ; then
CPPFLAGS="${CPPFLAGS} -DWITH_BIOSIG2" CPPFLAGS="${CPPFLAGS} -DWITH_BIOSIG2"
LIBBIOSIG_LDFLAGS="-lbiosig2 -lcholmod" LIBBIOSIG_LDFLAGS="-lbiosig -lcholmod"
elif test "$with_biosig" = "yes" ; then elif test "$with_biosig" = "yes" ; then
CPPFLAGS="${CPPFLAGS} -DWITH_BIOSIG" CPPFLAGS="${CPPFLAGS} -DWITH_BIOSIG"
LIBBIOSIG_LDFLAGS="-lbiosig -lcholmod" LIBBIOSIG_LDFLAGS="-lbiosig -lcholmod"
......
package: package:
name: py-stfio-debug name: py-stfio-debug
version: "0.15.4" version: "0.16.0"
source: source:
# Since this recipe is part of the git repo, the source is just a local path # Since this recipe is part of the git repo, the source is just a local path
......
package: package:
name: py-stfio name: py-stfio
version: "0.15.4" version: "0.16.0"
source: source:
# Since this recipe is part of the git repo, the source is just a local path # Since this recipe is part of the git repo, the source is just a local path
......
stimfit (0.16.0-1) unstable; urgency=low
* Upgrade to Python 3 (Closes: #938572)
-- Christoph Schmidt-Hieber <christsc@gmx.de> Fri, 06 Sep 2019 14:25:22 +0200
stimfit (0.15.8-1) unstable; urgency=low
* Address wx-gtk2 / wxpython-gtk3 incompatibility issue on bionic
(LP: #1778433)
-- Christoph Schmidt-Hieber <christsc@gmx.de> Fri, 29 Jun 2018 09:18:39 +0200
stimfit (0.15.6-1) unstable; urgency=low
* Adress shared library renaming error during debian packaging.
(Closes: #896407)
-- Christoph Schmidt-Hieber <christsc@gmx.de> Tue, 24 Apr 2018 23:05:28 +0200
stimfit (0.15.5-1) unstable; urgency=low
* Adds native intan CLP & tdms file reading
* Upgrade libbiosiglite to 1.9.1
-- Christoph Schmidt-Hieber <christsc@gmx.de> Mon, 12 Feb 2018 16:13:09 +0100
stimfit (0.15.4-1) unstable; urgency=low stimfit (0.15.4-1) unstable; urgency=low
* Fix building with gcc-6 on armhf (Closes: #847526) * Fix building with gcc-6 on armhf (Closes: #847526)
......
...@@ -3,14 +3,14 @@ Section: science ...@@ -3,14 +3,14 @@ Section: science
Priority: optional Priority: optional
Maintainer: Christoph Schmidt-Hieber <christsc@gmx.de> Maintainer: Christoph Schmidt-Hieber <christsc@gmx.de>
Uploaders: Yaroslav Halchenko <debian@onerussian.com> Uploaders: Yaroslav Halchenko <debian@onerussian.com>
Build-Depends: debhelper (>= 7), libboost-dev (>= 1.40.0), python-all-dev (>= 2.6.6-3), python-numpy, libhdf5-dev, swig, python-wxgtk3.0 | python-wxgtk2.8 (>= 2.8.9), python-wxgtk3.0-dev | libwxgtk2.8-dev (>= 2.8.9), libwxgtk3.0-dev | libwxgtk2.8-dev (>= 2.8.9), libfftw3-dev, liblapack-dev, chrpath, help2man, libsuitesparse-dev, zlib1g-dev, dh-autoreconf, pkg-config Build-Depends: debhelper (>= 9), dh-python, libboost-dev (>= 1.40.0), python3-all-dev, python3-numpy, libhdf5-dev, swig, python3-sip-dev, python3-wxgtk4.0, libwxgtk3.0-gtk3-dev, libfftw3-dev, liblapack-dev, chrpath, help2man, libsuitesparse-dev, zlib1g-dev, dh-autoreconf, pkg-config
Standards-Version: 3.9.7 Standards-Version: 3.9.8
Homepage: http://www.stimfit.org Homepage: http://www.stimfit.org
Package: stimfit Package: stimfit
Architecture: any Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, libsuitesparse-dev, zlib1g-dev, python-wxgtk3.0 | python-wxgtk2.8 (>= 2.8.9), python-numpy, python-matplotlib Depends: ${shlibs:Depends}, ${misc:Depends}, ${python3:Depends}, libsuitesparse-dev, zlib1g-dev, python3-wxgtk4.0, python3-numpy, python3-matplotlib
Recommends: python-scipy Recommends: python3-scipy
Description: Program for viewing and analyzing electrophysiological data Description: Program for viewing and analyzing electrophysiological data
Stimfit is a free, fast and simple program for viewing and analyzing Stimfit is a free, fast and simple program for viewing and analyzing
electrophysiological data. It features an embedded Python shell that electrophysiological data. It features an embedded Python shell that
...@@ -22,7 +22,7 @@ Section: debug ...@@ -22,7 +22,7 @@ Section: debug
Priority: extra Priority: extra
Architecture: any Architecture: any
Depends: ${misc:Depends}, stimfit Depends: ${misc:Depends}, stimfit
Recommends: python-matplotlib, python-scipy, python-stfio Recommends: python3-matplotlib, python3-scipy, python3-stfio
Description: Debug symbols for stimfit Description: Debug symbols for stimfit
Stimfit is a free, fast and simple program for viewing and analyzing Stimfit is a free, fast and simple program for viewing and analyzing
electrophysiological data. It features an embedded Python shell that electrophysiological data. It features an embedded Python shell that
...@@ -30,12 +30,12 @@ Description: Debug symbols for stimfit ...@@ -30,12 +30,12 @@ Description: Debug symbols for stimfit
libraries such as NumPy and SciPy. This package contains the debug libraries such as NumPy and SciPy. This package contains the debug
symbols for Stimfit. symbols for Stimfit.
Package: python-stfio Package: python3-stfio
Section: python Section: python
Architecture: any Architecture: any
Depends: ${python:Depends}, ${shlibs:Depends}, ${misc:Depends}, libsuitesparse-dev, zlib1g-dev, python-numpy Depends: ${python3:Depends}, ${shlibs:Depends}, ${misc:Depends}, libsuitesparse-dev, zlib1g-dev, python3-numpy
Provides: ${python:Provides} Provides: ${python3:Provides}
Recommends: python-matplotlib, python-scipy, python-pandas Recommends: python3-matplotlib, python3-scipy, python3-pandas
Description: Python module to read common electrophysiology file formats. Description: Python module to read common electrophysiology file formats.
The stfio module allows you to read common electrophysiology file formats The stfio module allows you to read common electrophysiology file formats
from Python. Axon binaries (abf), Axon text (atf), HEKA (dat), from Python. Axon binaries (abf), Axon text (atf), HEKA (dat),
......
#! /bin/bash #! /bin/bash
VERSION=0.15.4 VERSION=0.16.0
make dist make dist
mkdir -p ../deb/ mkdir -p ../deb/
...@@ -12,4 +12,4 @@ tar -xzf stimfit_${VERSION}.orig.tar.gz ...@@ -12,4 +12,4 @@ tar -xzf stimfit_${VERSION}.orig.tar.gz
cd stimfit-${VERSION} cd stimfit-${VERSION}
cp -rv ../../../dist/debian ./ cp -rv ../../../dist/debian ./
debuild -S -sa debuild -S -sa
sudo pbuilder build --basetgz /home/csh/pbuilder/unstable.tgz ../*.dsc sudo pbuilder build --basetgz /var/cache/pbuilder/base.tgz ../*.dsc
#! /bin/bash #! /bin/bash
VERSION=0.15.4 VERSION=0.16.0
make dist make dist
mkdir -p ../deb/ mkdir -p ../deb/
......
--- a/debian/control
+++ b/debian/control
@@ -3,13 +3,13 @@
Priority: optional
Maintainer: Christoph Schmidt-Hieber <christsc@gmx.de>
Uploaders: Yaroslav Halchenko <debian@onerussian.com>
-Build-Depends: debhelper (>= 7), libboost-dev (>= 1.40.0), python-all-dev (>= 2.6.6-3), python-numpy, libhdf5-dev, swig, python-wxgtk3.0 | python-wxgtk2.8 (>= 2.8.9), python-wxgtk3.0-dev | libwxgtk2.8-dev (>= 2.8.9), libwxgtk3.0-dev | libwxgtk2.8-dev (>= 2.8.9), libfftw3-dev, liblapack-dev, chrpath, help2man, libbiosig-dev, libsuitesparse-dev, dh-autoreconf
+Build-Depends: debhelper (>= 7), libboost-dev (>= 1.40.0), python-all-dev (>= 2.6.6-3), python-numpy, libhdf5-dev, swig, python-wxgtk2.8 (>= 2.8.9), libwxgtk2.8-dev (>= 2.8.9), libfftw3-dev, liblapack-dev, chrpath, help2man, libbiosig-dev, libsuitesparse-dev, dh-autoreconf
Standards-Version: 3.9.6
Homepage: http://www.stimfit.org
Package: stimfit
Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, libbiosig-dev, libsuitesparse-dev, python-wxgtk3.0 | python-wxgtk2.8 (>= 2.8.9), python-numpy, python-matplotlib
+Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, libbiosig-dev, libsuitesparse-dev, python-wxgtk2.8 (>= 2.8.9), python-numpy, python-matplotlib
Recommends: python-scipy
Description: Program for viewing and analyzing electrophysiological data
Stimfit is a free, fast and simple program for viewing and analyzing
#!/usr/bin/make -f #!/usr/bin/make -f
# Sample debian/rules that uses debhelper. # Sample debian/rules that uses debhelper.
# This file is public domain software, originally written by Joey Hess. # This file is public domain software, originally written by Joey Hess.
# #
# This version is for packages that are architecture independent. # This version is for packages that are architecture independent.
...@@ -8,7 +8,9 @@ ...@@ -8,7 +8,9 @@
export DH_VERBOSE=1 export DH_VERBOSE=1
DEBPREFIX=$(CURDIR)/debian/tmp/usr DEBPREFIX=$(CURDIR)/debian/tmp/usr
PYVER := $(shell pyversions -vd) PYVER := $(shell py3versions -vd)
# Whenever libwxgtk3.0-gtk3-dev installed and wx-config present, need custom opts
WXCONFIG_OPTS=$(shell wx-config --toolkit=gtk3 2>/dev/null 1>&2 && echo '--with-wx-config="wx-config --toolkit=gtk3"' || echo '')
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
...@@ -45,14 +47,14 @@ clean: ...@@ -45,14 +47,14 @@ clean:
install: build install: build
dh_autoreconf dh_autoreconf
./configure --enable-python --enable-debian --with-biosiglite --prefix=$(DEBPREFIX) PYTHON=/usr/bin/python$(PYVER) PYTHON_VERSION=$(PYVER) ./configure --enable-python --enable-debian --with-biosiglite --prefix=$(DEBPREFIX) $(WXCONFIG_OPTS)
$(MAKE) $(MAKE)
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
$(MAKE) check $(MAKE) check
endif endif
$(MAKE) install $(MAKE) install
./configure --enable-module --enable-debian --with-biosiglite --prefix=$(DEBPREFIX) PYTHON=/usr/bin/python$(PYVER) PYTHON_VERSION=$(PYVER) ./configure --enable-module --enable-debian --with-biosiglite --prefix=$(DEBPREFIX) $(WXCONFIG_OPTS)
$(MAKE) $(MAKE)
$(MAKE) install $(MAKE) install
...@@ -90,7 +92,7 @@ binary-arch: build install ...@@ -90,7 +92,7 @@ binary-arch: build install
# dh_lintian # dh_lintian
# dh_bugfiles # dh_bugfiles
# dh_undocumented # dh_undocumented
dh_python2 dh_python3
dh_installman $(CURDIR)/man/stimfit.1 dh_installman $(CURDIR)/man/stimfit.1
dh_install --sourcedir=$(CURDIR)/debian/tmp dh_install --sourcedir=$(CURDIR)/debian/tmp
dh_link dh_link
...@@ -99,7 +101,7 @@ binary-arch: build install ...@@ -99,7 +101,7 @@ binary-arch: build install
dh_fixperms dh_fixperms
dh_icons dh_icons
# dh_perl # dh_perl
[ -x /usr/bin/dh_python2 ] && dh_python2 -V$(PYVER) || : [ -x /usr/bin/dh_python3 ] && dh_python3 -V$(PYVER) --no-ext-rename || :
[ -x /usr/bin/dh_numpy ] && dh_numpy || : [ -x /usr/bin/dh_numpy ] && dh_numpy || :
dh_makeshlibs dh_makeshlibs
dh_shlibdeps dh_shlibdeps
......
#! /bin/bash #! /bin/bash
STFVERSION="0.15.4" STFVERSION="0.16.0"
MPDIR=`pwd` MPDIR=`pwd`
if [ "$1" != "" ]; then if [ "$1" != "" ]; then
...@@ -38,7 +38,9 @@ sudo port uninstall py-stfio ...@@ -38,7 +38,9 @@ sudo port uninstall py-stfio
sudo port clean --all py-stfio sudo port clean --all py-stfio
sudo port uninstall py27-stfio sudo port uninstall py27-stfio
sudo port clean --all py27-stfio sudo port clean --all py27-stfio
sudo port uninstall py34-stfio
sudo port clean --all py34-stfio
sudo port uninstall py35-stfio sudo port uninstall py35-stfio
sudo port clean --all py35-stfio sudo port clean --all py35-stfio
sudo port uninstall py36-stfio
sudo port clean --all py36-stfio
sudo port uninstall py37-stfio
sudo port clean --all py37-stfio
#! /bin/sh #! /bin/sh
CURDIR=`pwd` CURDIR=`pwd`
cd ~/macports cd ~/macports/dports
svn update git pull origin master
cd $CURDIR cd $CURDIR
declare -a arr=("python/py-stfio" "science/stimfit") declare -a arr=("python/py-stfio" "science/stimfit")
......
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$ # $Id$
PortSystem 1.0 PortSystem 1.0
PortGroup python 1.0 PortGroup python 1.0
name py-stfio name py-stfio
version 0.14.13 version 0.15.8
categories python science categories python science
platforms darwin platforms darwin
license GPL-2 license GPL-2
maintainers gmx.de:christsc maintainers {gmx.de:christsc @neurodroid}
description Electrophysiology file support for Python description Electrophysiology file support for Python
long_description A Python module to read common electrophysiology file formats. long_description A Python module to read common electrophysiology file formats.
homepage http://www.stimfit.org homepage http://www.stimfit.org
master_sites ${homepage} master_sites ${homepage}
distname stimfit-${version} distname stimfit-${version}
checksums rmd160 bdf89fe65cb65c0a3f40e0abe9c832a6e623afed \ checksums rmd160 960efd2fa4f88aba153af560cc49adc40090995b \
sha256 e3dd771129fea5bb6a250da4594bd2ba52e6fd73272b5d51ef2c005d38a0b7f3 sha256 0fc6b0f52057d9c45107557e615f314179ac92e180123ed9d1da98e7f812df8b
python.versions 27 34 35 python.versions 27 35 36 37
if { ${name} ne ${subport} } { if { ${name} ne ${subport} } {
depends_build port:swig-python depends_build port:swig-python
depends_lib port:boost \ depends_lib port:boost \
port:hdf5 \ port:hdf5 \
port:py${python.version}-cvxopt \
port:py${python.version}-matplotlib \ port:py${python.version}-matplotlib \
port:py${python.version}-numpy port:py${python.version}-numpy
...@@ -38,7 +38,7 @@ if { ${name} ne ${subport} } { ...@@ -38,7 +38,7 @@ if { ${name} ne ${subport} } {
use_configure yes use_configure yes
build.cmd make build.cmd make
build.target build.target
destroot.cmd make destroot.cmd make
destroot.destdir \ destroot.destdir \
DESTDIR=${destroot} DESTDIR=${destroot}
...@@ -50,14 +50,20 @@ if { ${name} ne ${subport} } { ...@@ -50,14 +50,20 @@ if { ${name} ne ${subport} } {
${worksrcpath}/COPYING ${docdir} ${worksrcpath}/COPYING ${docdir}
} }
variant biosig description {Use biosig library for file I/O.} { variant biosig conflicts biosiglite description {Use external biosig library for file I/O.} {
depends_lib-append \ depends_lib-append \
port:libbiosig port:libbiosig
configure.args-replace \ configure.args-replace \
--without-biosig \ --without-biosig \
--with-biosig --with-biosig2
}
variant biosiglite conflicts biosig description {Use internal biosiglite library for file I/O.} {
configure.args-replace \
--without-biosig \
--with-biosiglite
} }
default_variants +biosig default_variants +biosiglite
} }
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$ # $Id$
PortSystem 1.0 PortSystem 1.0
PortGroup python 1.0 PortGroup python 1.0
...@@ -9,7 +8,7 @@ version STFVERSION ...@@ -9,7 +8,7 @@ version STFVERSION
categories python science categories python science
platforms darwin platforms darwin
license GPL-2 license GPL-2
maintainers gmx.de:christsc maintainers {gmx.de:christsc @neurodroid}
description Electrophysiology file support for Python description Electrophysiology file support for Python
long_description A Python module to read common electrophysiology file formats. long_description A Python module to read common electrophysiology file formats.
homepage http://www.stimfit.org homepage http://www.stimfit.org
...@@ -19,13 +18,14 @@ distname stimfit-${version} ...@@ -19,13 +18,14 @@ distname stimfit-${version}
checksums rmd160 RMD160 \ checksums rmd160 RMD160 \
sha256 SHA256 sha256 SHA256
python.versions 27 34 35 python.versions 27 35 36 37
if { ${name} ne ${subport} } { if { ${name} ne ${subport} } {
depends_build port:swig-python depends_build port:swig-python
depends_lib port:boost \ depends_lib port:boost \
port:hdf5 \ port:hdf5 \
port:py${python.version}-cvxopt \
port:py${python.version}-matplotlib \ port:py${python.version}-matplotlib \
port:py${python.version}-numpy port:py${python.version}-numpy
...@@ -38,7 +38,7 @@ if { ${name} ne ${subport} } { ...@@ -38,7 +38,7 @@ if { ${name} ne ${subport} } {
use_configure yes use_configure yes
build.cmd make build.cmd make
build.target build.target
destroot.cmd make destroot.cmd make
destroot.destdir \ destroot.destdir \
DESTDIR=${destroot} DESTDIR=${destroot}
...@@ -50,7 +50,7 @@ if { ${name} ne ${subport} } { ...@@ -50,7 +50,7 @@ if { ${name} ne ${subport} } {
${worksrcpath}/COPYING ${docdir} ${worksrcpath}/COPYING ${docdir}
} }
variant biosig description {Use biosig library for file I/O.} { variant biosig conflicts biosiglite description {Use external biosig library for file I/O.} {
depends_lib-append \ depends_lib-append \
port:libbiosig port:libbiosig
...@@ -59,5 +59,11 @@ if { ${name} ne ${subport} } { ...@@ -59,5 +59,11 @@ if { ${name} ne ${subport} } {
--with-biosig2 --with-biosig2
} }
default_variants +biosig variant biosiglite conflicts biosig description {Use internal biosiglite library for file I/O.} {
configure.args-replace \
--without-biosig \
--with-biosiglite
}
default_variants +biosiglite
} }
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$ # $Id$
PortSystem 1.0 PortSystem 1.0
PortGroup wxWidgets 1.0 PortGroup wxWidgets 1.0
name stimfit name stimfit
version 0.14.13 version 0.15.8
categories science categories science
platforms darwin platforms darwin
license GPL-2 license GPL-2
maintainers gmx.de:christsc maintainers {gmx.de:christsc @neurodroid}
description Electrophysiology analysis suite description Electrophysiology analysis suite
long_description A program for viewing and analyzing electrophysiological data long_description A program for viewing and analyzing electrophysiological data
homepage http://www.stimfit.org homepage http://www.stimfit.org
master_sites ${homepage} master_sites ${homepage}
checksums rmd160 bdf89fe65cb65c0a3f40e0abe9c832a6e623afed \ checksums rmd160 960efd2fa4f88aba153af560cc49adc40090995b \
sha256 e3dd771129fea5bb6a250da4594bd2ba52e6fd73272b5d51ef2c005d38a0b7f3 sha256 0fc6b0f52057d9c45107557e615f314179ac92e180123ed9d1da98e7f812df8b
wxWidgets.use wxPython-3.0 wxWidgets.use wxPython-3.0
...@@ -39,7 +38,8 @@ variant python27 description {Build with Python shell.} { ...@@ -39,7 +38,8 @@ variant python27 description {Build with Python shell.} {
port:python27 \ port:python27 \
port:py27-wxpython-3.0 \ port:py27-wxpython-3.0 \
port:py27-numpy \ port:py27-numpy \
port:py27-matplotlib port:py27-matplotlib \
port:py27-cvxopt
configure.python \ configure.python \
${prefix}/bin/python2.7 ${prefix}/bin/python2.7
...@@ -57,24 +57,30 @@ variant atlas description {Use MacPorts ATLAS libraries.} { ...@@ -57,24 +57,30 @@ variant atlas description {Use MacPorts ATLAS libraries.} {
--with-lapack-lib=${prefix}/lib/libatlas.a --with-lapack-lib=${prefix}/lib/libatlas.a
} }
variant biosig description {Use biosig library for file I/O.} { variant biosig conflicts biosiglite description {Use external biosig library for file I/O.} {
depends_lib-append \ depends_lib-append \
port:libbiosig port:libbiosig
configure.args-replace \ configure.args-replace \
--without-biosig \ --without-biosig \
--with-biosig --with-biosig2
}
variant biosiglite conflicts biosig description {Use internal biosiglite library for file I/O.} {
configure.args-replace \
--without-biosig \
--with-biosiglite
} }
configure.ldflags-append \ configure.ldflags-append \
-headerpad_max_install_names -headerpad_max_install_names
# Commented out for now; will be required when wxpython gets available for Python 3.x # Commented out for now; will be required when wxpython gets available for Python 3.x
# if {![variant_isset python27]} { # if {![variant_isset python27]} {
default_variants +python27 default_variants +python27
# } # }
default_variants-append \ default_variants-append \
+biosig +biosiglite
destroot.destdir DESTDIR=${destroot}${applications_dir} destroot.destdir DESTDIR=${destroot}${applications_dir}
......
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$ # $Id$
PortSystem 1.0 PortSystem 1.0
PortGroup wxWidgets 1.0 PortGroup wxWidgets 1.0
...@@ -9,7 +8,7 @@ version STFVERSION ...@@ -9,7 +8,7 @@ version STFVERSION
categories science categories science
platforms darwin platforms darwin
license GPL-2 license GPL-2
maintainers gmx.de:christsc maintainers {gmx.de:christsc @neurodroid}
description Electrophysiology analysis suite description Electrophysiology analysis suite
long_description A program for viewing and analyzing electrophysiological data long_description A program for viewing and analyzing electrophysiological data
homepage http://www.stimfit.org homepage http://www.stimfit.org
...@@ -39,7 +38,8 @@ variant python27 description {Build with Python shell.} { ...@@ -39,7 +38,8 @@ variant python27 description {Build with Python shell.} {
port:python27 \ port:python27 \
port:py27-wxpython-3.0 \ port:py27-wxpython-3.0 \
port:py27-numpy \ port:py27-numpy \
port:py27-matplotlib port:py27-matplotlib \
port:py27-cvxopt
configure.python \ configure.python \
${prefix}/bin/python2.7 ${prefix}/bin/python2.7
...@@ -57,7 +57,7 @@ variant atlas description {Use MacPorts ATLAS libraries.} { ...@@ -57,7 +57,7 @@ variant atlas description {Use MacPorts ATLAS libraries.} {
--with-lapack-lib=${prefix}/lib/libatlas.a --with-lapack-lib=${prefix}/lib/libatlas.a
} }
variant biosig description {Use biosig library for file I/O.} { variant biosig conflicts biosiglite description {Use external biosig library for file I/O.} {
depends_lib-append \ depends_lib-append \
port:libbiosig port:libbiosig
...@@ -66,15 +66,21 @@ variant biosig description {Use biosig library for file I/O.} { ...@@ -66,15 +66,21 @@ variant biosig description {Use biosig library for file I/O.} {
--with-biosig2 --with-biosig2
} }
variant biosiglite conflicts biosig description {Use internal biosiglite library for file I/O.} {
configure.args-replace \
--without-biosig \
--with-biosiglite
}
configure.ldflags-append \ configure.ldflags-append \
-headerpad_max_install_names -headerpad_max_install_names
# Commented out for now; will be required when wxpython gets available for Python 3.x # Commented out for now; will be required when wxpython gets available for Python 3.x
# if {![variant_isset python27]} { # if {![variant_isset python27]} {
default_variants +python27 default_variants +python27
# } # }
default_variants-append \ default_variants-append \
+biosig +biosiglite
destroot.destdir DESTDIR=${destroot}${applications_dir} destroot.destdir DESTDIR=${destroot}${applications_dir}
......
<pkmkdoc spec="1.12"><properties><title>stimfit</title><build>/Users/cs/stimfit-0.15.4.pkg</build><organization>stimfit.org</organization><userSees ui="easy"/><min-target os="2"/><domain system="true"/></properties><distribution><versions min-spec="1.000000"/><scripts></scripts></distribution><description></description><contents><choice title="stimfit" id="choice20" starts_selected="true" starts_enabled="true" starts_hidden="false"><pkgref id="stimfit.org.stimfit.stimfit.pkg"/></choice></contents><resources bg-scale="none" bg-align="bottomright"><locale lang="en"><resource type="license">/Users/cs/stimfit/gpl-2.0.txt</resource></locale></resources><flags/><item type="file">01stimfit.xml</item><mod>properties.systemDomain</mod><mod>properties.title</mod><mod>properties.anywhereDomain</mod><mod>postinstallActions.actions</mod></pkmkdoc> <pkmkdoc spec="1.12"><properties><title>stimfit</title><build>/Users/cs/stimfit-0.16.0.pkg</build><organization>stimfit.org</organization><userSees ui="easy"/><min-target os="2"/><domain system="true"/></properties><distribution><versions min-spec="1.000000"/><scripts></scripts></distribution><description></description><contents><choice title="stimfit" id="choice20" starts_selected="true" starts_enabled="true" starts_hidden="false"><pkgref id="stimfit.org.stimfit.stimfit.pkg"/></choice></contents><resources bg-scale="none" bg-align="bottomright"><locale lang="en"><resource type="license">/Users/cs/stimfit/gpl-2.0.txt</resource></locale></resources><flags/><item type="file">01stimfit.xml</item><mod>properties.systemDomain</mod><mod>properties.title</mod><mod>properties.anywhereDomain</mod><mod>postinstallActions.actions</mod></pkmkdoc>
\ No newline at end of file \ No newline at end of file
#! /bin/bash #! /bin/bash
prefix="/opt/local" prefix="/opt/local"
PYVER=3.4 PYVER=2.7
MYCC=/usr/bin/clang MYCC=/usr/bin/clang
MYCXX=/usr/bin/clang++ MYCXX=/usr/bin/clang++
...@@ -9,6 +9,6 @@ MYLD=ld ...@@ -9,6 +9,6 @@ MYLD=ld
config_args="--disable-dependency-tracking \ config_args="--disable-dependency-tracking \
--enable-module \ --enable-module \
--with-biosig" --with-biosiglite"
../../configure ${config_args} CC="${MYCC} -I${prefix}/include" CXX="${MYCXX} -I${prefix}/include" LD="${MYLD}" LDFLAGS="-headerpad_max_install_names -L${prefix}/lib" PYTHON="${prefix}/bin/python${PYVER}" ../../configure ${config_args} CC="${MYCC} -I${prefix}/include" CXX="${MYCXX} -I${prefix}/include" LD="${MYLD}" LDFLAGS="-headerpad_max_install_names -L${prefix}/lib" PYTHON="${prefix}/bin/python${PYVER}"
...@@ -9,7 +9,7 @@ MYLD=`${WX_CONF} --ld` ...@@ -9,7 +9,7 @@ MYLD=`${WX_CONF} --ld`
config_args="--with-wx-config=${WX_CONF} \ config_args="--with-wx-config=${WX_CONF} \
--disable-dependency-tracking \ --disable-dependency-tracking \
--with-biosig2" --with-biosiglite"
# --with-lapack-lib=/opt/local/lib/libatlas.a \ # --with-lapack-lib=/opt/local/lib/libatlas.a \
# --enable-debug \ # --enable-debug \
......
#! /bin/bash #! /bin/bash
hdiutil create stimfit-0.15.4.dmg -srcfolder ./stimfit.app -ov -format UDBZ hdiutil create stimfit-0.16.0.dmg -srcfolder ./stimfit.app -ov -format UDBZ
...@@ -26,13 +26,13 @@ ...@@ -26,13 +26,13 @@
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>0.15.4</string> <string>0.16.0</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>0.15.4</string> <string>0.16.0</string>
<key>CFBundleGetInfoString</key> <key>CFBundleGetInfoString</key>
<string>stimfit version 0.15.4, (c) 2003-2011 C. Schmidt-Hieber</string> <string>stimfit version 0.16.0, (c) 2003-2011 C. Schmidt-Hieber</string>
<key>CFBundleLongVersionString</key> <key>CFBundleLongVersionString</key>
<string>0.15.4, (c) 2003-2011 C. Schmidt-Hieber</string> <string>0.16.0, (c) 2003-2011 C. Schmidt-Hieber</string>
<key>NSHumanReadableCopyright</key> <key>NSHumanReadableCopyright</key>
<string>Copyright 2003-2011 C. Schmidt-Hieber</string> <string>Copyright 2003-2011 C. Schmidt-Hieber</string>
<key>LSRequiresCarbon</key> <key>LSRequiresCarbon</key>
......
...@@ -20,4 +20,9 @@ ...@@ -20,4 +20,9 @@
Name="PYTHONDIR" Name="PYTHONDIR"
Value="C:\Python27" Value="C:\Python27"
/> />
<UserMacro
Name="NUMPYDIR"
Value="C:\Python27\Lib\site-packages\numpy\core\include"
/>
</VisualStudioPropertySheet> </VisualStudioPropertySheet>
...@@ -121,7 +121,7 @@ ...@@ -121,7 +121,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;" AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\Lib\site-packages\numpy\core\include&quot;"
PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2" PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
...@@ -278,7 +278,7 @@ ...@@ -278,7 +278,7 @@
Optimization="3" Optimization="3"
EnableIntrinsicFunctions="true" EnableIntrinsicFunctions="true"
WholeProgramOptimization="false" WholeProgramOptimization="false"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;" AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\Lib\site-packages\numpy\core\include&quot;"
PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2" PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
RuntimeLibrary="2" RuntimeLibrary="2"
EnableFunctionLevelLinking="true" EnableFunctionLevelLinking="true"
......
...@@ -144,7 +144,7 @@ ...@@ -144,7 +144,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="hdf5.lib hdf5_hl.lib libbiosig2.lib" AdditionalDependencies="hdf5.lib hdf5_hl.lib libbiosig.lib"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="&quot;$(HDF5DIR)\lib&quot;;&quot;$(BIOSIGDIR)\lib&quot;" AdditionalLibraryDirectories="&quot;$(HDF5DIR)\lib&quot;;&quot;$(BIOSIGDIR)\lib&quot;"
IgnoreDefaultLibraryNames="libc.lib;libcmt.lib" IgnoreDefaultLibraryNames="libc.lib;libcmt.lib"
...@@ -305,7 +305,7 @@ ...@@ -305,7 +305,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="hdf5.lib hdf5_hl.lib libbiosig2.lib" AdditionalDependencies="hdf5.lib hdf5_hl.lib libbiosig.lib"
LinkIncremental="1" LinkIncremental="1"
AdditionalLibraryDirectories="&quot;$(HDF5DIR)\lib&quot;;&quot;$(BIOSIGDIR)\lib&quot;" AdditionalLibraryDirectories="&quot;$(HDF5DIR)\lib&quot;;&quot;$(BIOSIGDIR)\lib&quot;"
IgnoreDefaultLibraryNames="libc.lib;libcmt.lib" IgnoreDefaultLibraryNames="libc.lib;libcmt.lib"
...@@ -587,6 +587,22 @@ ...@@ -587,6 +587,22 @@
> >
</File> </File>
</Filter> </Filter>
<Filter
Name="intan"
>
<File
RelativePath="..\..\..\..\src\libstfio\intan\common.h"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\intanlib.h"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\streams.h"
>
</File>
</Filter>
</Filter> </Filter>
<Filter <Filter
Name="Source Files" Name="Source Files"
...@@ -787,6 +803,22 @@ ...@@ -787,6 +803,22 @@
> >
</File> </File>
</Filter> </Filter>
<Filter
Name="intan"
>
<File
RelativePath="..\..\..\..\src\libstfio\intan\common.cpp"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\intanlib.cpp"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\streams.cpp"
>
</File>
</Filter>
</Filter> </Filter>
<Filter <Filter
Name="Resource Files" Name="Resource Files"
......
...@@ -20,4 +20,8 @@ ...@@ -20,4 +20,8 @@
Name="PYTHONDIR" Name="PYTHONDIR"
Value="C:\Python27" Value="C:\Python27"
/> />
<UserMacro
Name="NUMPYDIR"
Value="C:\Python27\Lib\site-packages\numpy\core\include"
/>
</VisualStudioPropertySheet> </VisualStudioPropertySheet>
...@@ -122,7 +122,7 @@ ...@@ -122,7 +122,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;" AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;;&quot;$(NUMPYDIR)&quot;"
PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2" PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="3" BasicRuntimeChecks="3"
...@@ -281,7 +281,7 @@ ...@@ -281,7 +281,7 @@
Optimization="3" Optimization="3"
EnableIntrinsicFunctions="true" EnableIntrinsicFunctions="true"
WholeProgramOptimization="false" WholeProgramOptimization="false"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;" AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;;&quot;$(NUMPYDIR)&quot;"
PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2" PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
RuntimeLibrary="2" RuntimeLibrary="2"
EnableFunctionLevelLinking="true" EnableFunctionLevelLinking="true"
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
> >
<UserMacro <UserMacro
Name="SWIGBIN" Name="SWIGBIN"
Value="C:\cygwin64\bin\swig.exe" Value="$(SolutionDir)\..\..\..\..\..\swigwin\swig.exe"
PerformEnvironmentSet="true" PerformEnvironmentSet="true"
/> />
<UserMacro <UserMacro
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
/> />
<UserMacro <UserMacro
Name="NUMPYDIR" Name="NUMPYDIR"
Value="$(SolutionDir)\..\..\..\..\..\stf-site-packages\numpy\core\include" Value="C:\Python27\Lib\site-packages\numpy\core\include"
/> />
<UserMacro <UserMacro
Name="WXDIR" Name="WXDIR"
......
...@@ -6,12 +6,12 @@ ...@@ -6,12 +6,12 @@
> >
<UserMacro <UserMacro
Name="SWIGBIN" Name="SWIGBIN"
Value="C:\cygwin64\bin\swig.exe" Value="$(SolutionDir)\..\..\..\..\..\swigwin\swig.exe"
PerformEnvironmentSet="true" PerformEnvironmentSet="true"
/> />
<UserMacro <UserMacro
Name="NUMPYDIR" Name="NUMPYDIR"
Value="$(SolutionDir)\..\..\..\..\..\stf-site-packages\numpy\core\include" Value="C:\Python27\Lib\site-packages\numpy\core\include"
/> />
<UserMacro <UserMacro
Name="PYTHONDIR" Name="PYTHONDIR"
......
This diff is collapsed.
...@@ -31,7 +31,7 @@ PROJECT_NAME = Stimfit ...@@ -31,7 +31,7 @@ PROJECT_NAME = Stimfit
# This could be handy for archiving the generated documentation or # This could be handy for archiving the generated documentation or
# if some version control system is used. # if some version control system is used.
PROJECT_NUMBER = 0.15.4 PROJECT_NUMBER = 0.16.0
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
# base path where the generated documentation will be put. # base path where the generated documentation will be put.
......
...@@ -15,6 +15,8 @@ ...@@ -15,6 +15,8 @@
# serve to show the default. # serve to show the default.
import sys, os import sys, os
from sphinx import __display_version__
from sphinx.errors import VersionRequirementError
# If your extensions (or modules documented by autodoc) are in another directory, # If your extensions (or modules documented by autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the # add these directories to sys.path here. If the directory is relative to the
...@@ -23,10 +25,15 @@ import sys, os ...@@ -23,10 +25,15 @@ import sys, os
# General configuration # General configuration
# --------------------- # ---------------------
needs_sphinx = '1.4.3' # required for sphinx.ext.imgmath
current_sphinx = __display_version__
if needs_sphinx > current_sphinx:
msg = 'Stimfit documentation needs at least Sphinx v%s' %needs_sphinx
raise VersionRequirementError( msg )
# Add any Sphinx extension module names here, as strings. They can be extensions # Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones. # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.doctest', 'sphinx.ext.intersphinx','sphinx.ext.pngmath'] extensions = ['sphinx.ext.autodoc', 'sphinx.ext.doctest', 'sphinx.ext.intersphinx','sphinx.ext.imgmath']
# Add any paths that contain templates here, relative to this directory. # Add any paths that contain templates here, relative to this directory.
templates_path = ['.templates'] templates_path = ['.templates']
...@@ -42,16 +49,16 @@ master_doc = 'contents' ...@@ -42,16 +49,16 @@ master_doc = 'contents'
# General information about the project. # General information about the project.
project = u'Stimfit' project = u'Stimfit'
copyright = u'2015, Christoph Schmidt-Hieber' copyright = u'2018, Christoph Schmidt-Hieber'
# The version info for the project you're documenting, acts as replacement for # The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the # |version| and |release|, also used in various other places throughout the
# built documents. # built documents.
# #
# The short X.Y version. # The short X.Y version.
version = '0.15.4' version = '0.16.0'
# The full version, including alpha/beta/rc tags. # The full version, including alpha/beta/rc tags.
release = '0.15.4' release = '0.16.0'
# The language for content autogenerated by Sphinx. Refer to documentation # The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages. # for a list of supported languages.
......
...@@ -82,7 +82,7 @@ The amplitude function will be calculated based on the traces selected by *trace ...@@ -82,7 +82,7 @@ The amplitude function will be calculated based on the traces selected by *trace
Code commented Code commented
============== ==============
*None* is a Python built-in constant. It is used in to represent the absence of a value. Therefore, in our example, when the argument *trace* is empty (its value is *None*) we will simply select the current trace with :func:`stf.get_trace_index()` and store it in the variable **sweep**. If not, the variable **sweep** will take the value taken by *trace*. This iscontroled by the following if-block within the function: *None* is a Python built-in constant. It is used in to represent the absence of a value. Therefore, in our example, when the argument *trace* is empty (its value is *None*) we will select the current trace with :func:`stf.get_trace_index()` and store it in the variable **sweep**. If not, the variable **sweep** will take the value taken by *trace*. This iscontroled by the following if-block within the function:
:: ::
...@@ -108,7 +108,7 @@ Note that after setting the stf cursors, we update the measurements in the trace ...@@ -108,7 +108,7 @@ Note that after setting the stf cursors, we update the measurements in the trace
Usage Usage
===== =====
The function accepts an optional *trace* argument. That means, that we do not need to declare it when using the function. In that case, the function will work on the current trace. For example, if we want to calculate the amplitude between a baseline between (500+10) msec and a peak between 750 and 760 msec on the current trace, we simply enter: The function accepts an optional *trace* argument. That means, that we do not need to declare it when using the function. In that case, the function will work on the current trace. For example, if we want to calculate the amplitude between a baseline between (500+10) msec and a peak between 750 and 760 msec on the current trace, we enter:
:: ::
......
...@@ -139,7 +139,7 @@ this will look for events below the value -40 but not in the current trace, only ...@@ -139,7 +139,7 @@ this will look for events below the value -40 but not in the current trace, only
>>> spells.count_events(threshold=-40,start=500,up=False,delta=1000,mark=False,trace=10) >>> spells.count_events(threshold=-40,start=500,up=False,delta=1000,mark=False,trace=10)
If you want to create a list of events with the events found in a selection of traces, you can simply type: If you want to create a list of events with the events found in a selection of traces, you can type:
:: ::
......
...@@ -94,7 +94,7 @@ To make the experience more interactive, we can load the string of the file with ...@@ -94,7 +94,7 @@ To make the experience more interactive, we can load the string of the file with
Usage Usage
===== =====
To see how both function work simply import the spells module in the Python console of Stimfit and try the example files. For example: To see how both function work import the spells module in the Python console of Stimfit and try the example files. For example:
:: ::
......
...@@ -15,13 +15,13 @@ This document collects answers to some questions like "How do I make ... in `Sti ...@@ -15,13 +15,13 @@ This document collects answers to some questions like "How do I make ... in `Sti
It assumes a basic knowledge of the embedded Python shell of `Stimfit <http://www.stimfit.org>`_. Some Python knowledge and a substantial proficiency in `Stimfit <http://www.stimfit.org>`_ are recommendable. Please note that this is not a Python manual, but a way to use Python for some basic analysis tasks provided with `Stimfit <http://www.stimfit.org>`_. For a detailed Python manual, we encourage the user to visit the official Python documentation on the [Python-website]_ and to read carefully the :doc:`/manual/index`. It assumes a basic knowledge of the embedded Python shell of `Stimfit <http://www.stimfit.org>`_. Some Python knowledge and a substantial proficiency in `Stimfit <http://www.stimfit.org>`_ are recommendable. Please note that this is not a Python manual, but a way to use Python for some basic analysis tasks provided with `Stimfit <http://www.stimfit.org>`_. For a detailed Python manual, we encourage the user to visit the official Python documentation on the [Python-website]_ and to read carefully the :doc:`/manual/index`.
The functions described along this document are available in your current `Stimfit <http://www.stimfit.org>`_ version. To make use of them you have simply to type the following line in the `Stimfit <http://www.stimfit.org>`_ embedded Python shell: The functions described along this document are available in your current `Stimfit <http://www.stimfit.org>`_ version. To make use of them you have to type the following line in the `Stimfit <http://www.stimfit.org>`_ embedded Python shell:
:: ::
>>> import spells >>> import spells
After that, functions can be called with the dot notation (i.e just typing **spells** before the function) For example, if we want to call the function rmean() we would simply do it in this way: After that, functions can be called with the dot notation (i.e just typing **spells** before the function) For example, if we want to call the function rmean() we would do it in this way:
:: ::
......
...@@ -50,7 +50,7 @@ We will start with a basic example to start using objects in the embedded Python ...@@ -50,7 +50,7 @@ We will start with a basic example to start using objects in the embedded Python
self.owner = owner self.owner = owner
We can save this class in a file called test.py and import into our Python session. After importing the file, nothing will happen. This is because we simply loaded the class (i.e instructions of how to create the object), but not the object itself. Now, we can create an object called **myTrace** with the instructions described in that class as follows: We can save this class in a file called test.py and import into our Python session. After importing the file, nothing will happen. This is because we loaded the class (i.e instructions of how to create the object), but not the object itself. Now, we can create an object called **myTrace** with the instructions described in that class as follows:
>>> myTrace= test.Trace('root') # test.py contains the class Trace() >>> myTrace= test.Trace('root') # test.py contains the class Trace()
...@@ -60,7 +60,7 @@ myTrace is now my particular object. It was created with the instructions given ...@@ -60,7 +60,7 @@ myTrace is now my particular object. It was created with the instructions given
Object attributes Object attributes
================= =================
Object attributes can be accessed with the dot notation. To test the attributes of "myTrace" we simply type: Object attributes can be accessed with the dot notation. To test the attributes of "myTrace" we type:
>>> myTrace.dt >>> myTrace.dt
>>> 0.05000000074505806 >>> 0.05000000074505806
...@@ -79,13 +79,13 @@ As you can see bellow, nothing would prevent us to assign a new value to any of ...@@ -79,13 +79,13 @@ As you can see bellow, nothing would prevent us to assign a new value to any of
>>> myTrace.dt = 3 >>> myTrace.dt = 3
This potentially very dangerous (imagine the consecuences of setting the sampling rate to 3 in further calculations). For that reason, it is a very good programming practice to hide some object attributes to the user. This is called **encapsulation**. To hide the attributes of "myTrace", we have just to insert a single underscore before the attribute in the class. These objects are **private** which simply means, "look, but do not touch!" This potentially very dangerous (imagine the consecuences of setting the sampling rate to 3 in further calculations). For that reason, it is a very good programming practice to hide some object attributes to the user. This is called **encapsulation**. To hide the attributes of "myTrace", we have just to insert a single underscore before the attribute in the class. These objects are **private** which means, "look, but do not touch!"
.. note:: .. note::
Python strongly relies on convention rather than on enforcement. For example, encapsulated attributes are not really private (i.e user can overwrite them if necessary), but the underscore notation is used to indicate internal use only. If you find a good reason to overwrite them, Python is not going to stop you. However, it is a good programming practice to keep the Python conventions if you want to share your programs with other users. Python strongly relies on convention rather than on enforcement. For example, encapsulated attributes are not really private (i.e user can overwrite them if necessary), but the underscore notation is used to indicate internal use only. If you find a good reason to overwrite them, Python is not going to stop you. However, it is a good programming practice to keep the Python conventions if you want to share your programs with other users.
Additionally, we could give the user the opportunity to retrieve these values without the dot notation by simply creating some functions available to this object. These would be the object methods. For example, we can create 2 functions called get_sampling_interval() and get_trace_index() inside the class. These are the methods of the object. Additionally, we could give the user the opportunity to retrieve these values without the dot notation by creating some functions available to this object. These would be the object methods. For example, we can create 2 functions called get_sampling_interval() and get_trace_index() inside the class. These are the methods of the object.
:: ::
...@@ -173,7 +173,7 @@ As soon as we move through the recording, the trace index may change. However, i ...@@ -173,7 +173,7 @@ As soon as we move through the recording, the trace index may change. However, i
""" get trace index """ """ get trace index """
return self._trace return self._trace
After reloading this class, and creating "myTrace" we can use the update() method. This simply collects the current trace index and sampling interval. If we change the trace or even the window, we have to call update() again to retreive the current index and sampling interval. After reloading this class, and creating "myTrace" we can use the update() method. This collects the current trace index and sampling interval. If we change the trace or even the window, we have to call update() again to retreive the current index and sampling interval.
>>> myTrace3 = test.myTrace('user') >>> myTrace3 = test.myTrace('user')
>>> myTrace3.get_trace_index() >>> myTrace3.get_trace_index()
...@@ -189,7 +189,7 @@ After reloading this class, and creating "myTrace" we can use the update() metho ...@@ -189,7 +189,7 @@ After reloading this class, and creating "myTrace" we can use the update() metho
Class inheritance Class inheritance
================= =================
Object-oriented languages like Python support class inheritance. This means that we can inherit attributes and methods from a pre-existing class. Thus, we do not need to rewrite again this code. We can simply inherit from another class (called mother class). Object-oriented languages like Python support class inheritance. This means that we can inherit attributes and methods from a pre-existing class. Thus, we do not need to rewrite again this code. We can inherit from another class (called mother class).
To inherit code from another class, we have to add the name of the mother class in the class headline. For example: To inherit code from another class, we have to add the name of the mother class in the class headline. For example:
>>> class Channel(Trace): >>> class Channel(Trace):
......
...@@ -259,11 +259,11 @@ and move after that to another trace, we could calculate the difference between ...@@ -259,11 +259,11 @@ and move after that to another trace, we could calculate the difference between
the former will give the peak value when in the trace where the object was created, and the later will return the peak in the current trace. the former will give the peak value when in the trace where the object was created, and the later will return the peak in the current trace.
Additionally, we can decide to change the threshold value of the AP in a trace. For that, we can simply type: Additionally, we can decide to change the threshold value of the AP in a trace. For that, we can type:
>>> myspike(20) >>> myspike(20)
And now the Spike attributes will be updated with the new threshold in the current trace. The function __call__ simply allows to call the object with a given argument, and we used it to set a different threshold and update the object attributes. And now the Spike attributes will be updated with the new threshold in the current trace. The function __call__ allows to call the object with a given argument, and we used it to set a different threshold and update the object attributes.
===== =====
Usage Usage
...@@ -300,7 +300,7 @@ Additionally, we have methods like **get_tamplitude()**, **get_threshold()** and ...@@ -300,7 +300,7 @@ Additionally, we have methods like **get_tamplitude()**, **get_threshold()** and
>>> latency = dend.t50_left - soma.t50_left >>> latency = dend.t50_left - soma.t50_left
You can find the class Spike described above in your current `Stimfit <http://www.stimfit.org>`_ version. To use it, you can simply import it from the spells module with the following command; You can find the class Spike described above in your current `Stimfit <http://www.stimfit.org>`_ version. To use it, you can import it from the spells module with the following command;
>>> from spells import Spike >>> from spells import Spike
>>> soma = Spike(50) >>> soma = Spike(50)
......
...@@ -5,7 +5,7 @@ Resistance Calculation ...@@ -5,7 +5,7 @@ Resistance Calculation
:Authors: Jose Guzman :Authors: Jose Guzman
:Updated: |today| :Updated: |today|
The resistance can be simply calculated using Ohm's law. Currents passing through the pipette will be proportional to the applied voltage difference. This proportional factor is the resistance. The resistance can be calculated using Ohm's law. Currents passing through the pipette will be proportional to the applied voltage difference. This proportional factor is the resistance.
.. math:: .. math::
...@@ -101,7 +101,7 @@ Now base_starts should be given in units of x (i.e ms). This is more intiutive i ...@@ -101,7 +101,7 @@ Now base_starts should be given in units of x (i.e ms). This is more intiutive i
===== =====
Usage Usage
===== =====
Now, you can use this function for different purposes. For example, you may want to test the value of the series resistance in response to a 5 mV hyperpolarizing pulse. First, let's assume that your recording has the current peak between the 10700 and 10999 sampling points. You should set the baseline (for example between 0 and 999) and then peak between 10700 and 10999. After that, and given that 5 mV is the voltage difference, you simply type: Now, you can use this function for different purposes. For example, you may want to test the value of the series resistance in response to a 5 mV hyperpolarizing pulse. First, let's assume that your recording has the current peak between the 10700 and 10999 sampling points. You should set the baseline (for example between 0 and 999) and then peak between 10700 and 10999. After that, and given that 5 mV is the voltage difference, you type:
>>> spells.resistance(0,999,10700,1999,-5) >>> spells.resistance(0,999,10700,1999,-5)
......
...@@ -7,7 +7,7 @@ Running mean ...@@ -7,7 +7,7 @@ Running mean
The running mean (or running average) is simple way to smooth the data. Given a certain set of points, a running average will create a new set of data points which will be computed by adding a series of averages of different subsets of the full data set. The running mean (or running average) is simple way to smooth the data. Given a certain set of points, a running average will create a new set of data points which will be computed by adding a series of averages of different subsets of the full data set.
Given for example a sequence :math:`X` of :math:`n` points, we can create a new set of data points :math:`S` of length :math:`n` by simply taking the average of a subset of :math:`w` points from the original data set for every point :math:`S_i` within the set: Given for example a sequence :math:`X` of :math:`n` points, we can create a new set of data points :math:`S` of length :math:`n` by taking the average of a subset of :math:`w` points from the original data set for every point :math:`S_i` within the set:
.. math:: .. math::
...@@ -81,7 +81,7 @@ Code commented ...@@ -81,7 +81,7 @@ Code commented
>>> sweep = stf.get_trace(trace,channel) >>> sweep = stf.get_trace(trace,channel)
:func:`stf.get_trace()` simply imports the **trace** of the **channel** into a 1D-Numpy array that we called sweep. The default values provided by the function are -1. This means that by default, the current trace/channel will be imported. :func:`stf.get_trace()` imports the **trace** of the **channel** into a 1D-Numpy array that we called sweep. The default values provided by the function are -1. This means that by default, the current trace/channel will be imported.
We create a new stf window with the following We create a new stf window with the following
...@@ -95,7 +95,7 @@ where dsweep is the 1D-NumPy array obtained after performing the running averag ...@@ -95,7 +95,7 @@ where dsweep is the 1D-NumPy array obtained after performing the running averag
Usage Usage
===== =====
To perform the running average of 10 sampling points of the current trace, simply type: To perform the running average of 10 sampling points of the current trace, type:
:: ::
......
...@@ -18,28 +18,53 @@ Then, you need the `Stimfit <http://www.stimfit.org>`_ source code: ...@@ -18,28 +18,53 @@ Then, you need the `Stimfit <http://www.stimfit.org>`_ source code:
$ cd $HOME $ cd $HOME
$ git clone https://github.com/neurodroid/stimfit.git $ git clone https://github.com/neurodroid/stimfit.git
This will download the code to a directory called *stfio*. It will download the code to a directory called *stimfit*.
Next, you need to generate the build system: Next, you need to generate the build system:
:: ::
$ cd $HOME/stfio $ cd $HOME/stimfit
$ ./autogen.sh $ ./autogen.sh
Now you can configure. I strongly recommend building in a separate directory. Now you can configure. I strongly recommend building in a separate directory.
:: ::
$ cd $HOME/stfio $ cd $HOME/stimfit
$ mkdir build $ mkdir build
$ cd build $ cd build
$ mkdir module $ mkdir module
$ cd module $ cd module
$ ../../configure --enable-module $ ../../configure --enable-module
Remember to add the argument *--with-biosig* to the configure script We recommend to use BioSig to read extra biomedical fileformats (see :ref:`BioSigBuild`) :
if you want to have extra biomedical fileformats for stfio.
::
$ ../../configure --enable-module --with-biosiglite
===================================================
Building stfio for non-default Python distributions
===================================================
To install the *stfio* module in distributions such as **Anaconda Python**, use the argument *--prefix=* to specify the path where the Python distribution is installed. For example, to install *stfio* for Anaconda Python 2.7 use:
::
$ ../../configure --enable-module --prefix=$HOME/anaconda/
If using virtual environment, try something like this:
::
$ ../../configure --enable-module --prefix=$HOME/anaconda/envs/py36
Other Python versions are also possible. For example, to install the module in your local Python version, you could use:
::
$ ../../configure --enable-module --prefix=$HOME/.local/lib/python2.7
Then, build and install: Then, build and install:
......
...@@ -201,7 +201,7 @@ First, you have to select the traces to average (Fig. 14). Once you are done, cl ...@@ -201,7 +201,7 @@ First, you have to select the traces to average (Fig. 14). Once you are done, cl
.. note:: .. note::
If you want to perform an average (or any other measurement) of all traces in a recording, simply select Edit-> Select all, or type Ctrl+A