Commit 1a9862da authored by JoseGuzman's avatar JoseGuzman

update url for 2018 publications

parents 5d4492c6 8b07cc63
......@@ -211,8 +211,8 @@ endif
CC ?= $(shell $(WXCONF) --cc)
CXX ?= $(shell $(WXCONF) --cxx)
CFLAGS = $(DEFINES) $(shell $(WXCONF) --cflags) -fstack-protector -O2
CPPFLAGS = $(DEFINES) $(shell $(WXCONF) --cppflags) -std=gnu++11 -fstack-protector -O2
CXXFLAGS = $(DEFINES) $(shell $(WXCONF) --cxxflags) -std=gnu++11 -fstack-protector -O2
CPPFLAGS = $(DEFINES) $(shell $(WXCONF) --cppflags) -std=gnu++17 -fstack-protector -O2
CXXFLAGS = $(DEFINES) $(shell $(WXCONF) --cxxflags) -std=gnu++17 -fstack-protector -O2
LIBS += $(shell $(WXCONF) --libs net,adv,aui,core,base)
......@@ -227,11 +227,6 @@ mandir = ${datarootdir}/man
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
CXXFLAGS += -fabi-version=2
endif
CPPFLAGS += -I$(WXDIR)
## HDF5 related stuff ##
......@@ -261,7 +256,7 @@ else
LDFLAGS += -L/usr/lib/$(PLATFORM)
LIBS += -lhdf5_serial_hl -lhdf5_serial
else
LIBS += -lhdf5_hl -lhdf5
LIBS += -lhdf5_hl -lhdf5 -lz
endif
endif
endif
......@@ -283,9 +278,8 @@ LIBS += -lfftw3
ifeq (mingw,$(findstring mingw, $(WXCONF)))
LIBS += -lgfortran -lquadmath
LIBS += -liberty -liconv
endif
LIBS += -liconv -ltinyxml -lstdc++
LIBS += -ltinyxml -lstdc++
##############################################################
......
......@@ -136,10 +136,10 @@ if test "$with_pslope" = "yes" ; then
CPPFLAGS="${CPPFLAGS} -DWITH_PSLOPE"
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")
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")
AC_ARG_WITH([biosiglite], AS_HELP_STRING([--with-biosiglite], [use builtin biosig library]), [])
......
......@@ -39,6 +39,8 @@ References
* `Rothman JS and Silver RA (2018) <https://www.frontiersin.org/articles/10.3389/fninf.2018.00014/full>`_ NeuroMatic: An Integrated Open-Source Software Toolkit for Acquisition, Analysis and Simulation of Electrophysiological Data. *Front Neuroinform* doi: 10.3389/fninf.2018.00014.
* Booker, S. A., Domanski, A. P., Dando, O. R., Jackson, A. D., Isaac, J. T., Hardingham, G. E., ... & Kind, P. C. (2018). Altered dendritic spine function and integration in a mouse model of Fragile X Syndrome. bioRxiv, 396986.
====
2017
====
......
......@@ -14,7 +14,11 @@
#pragma once
#include <stdlib.h>
#include <boost/shared_array.hpp>
#if (__cplusplus < 201402L)
# include <boost/shared_array.hpp>
#else
# include <memory>
#endif
#if defined(__UNIX__) || defined(__STF__)
#define max(a,b) (((a) > (b)) ? (a) : (b))
......@@ -29,7 +33,11 @@ template<class ITEM>
class CArrayPtr
{
private: // Private data.
#if (__cplusplus < 201402L)
boost::shared_array<ITEM> m_pArray;
#else
std::shared_ptr<ITEM> m_pArray;
#endif
private: // Prevent copy constructors and operator=().
CArrayPtr(const CArrayPtr &);
......
......@@ -13,7 +13,11 @@
#define INC_FILEREADCACHE_HPP
#include "./../Common/FileIO.hpp"
#include <boost/shared_array.hpp>
#if (__cplusplus < 201402L)
# include <boost/shared_array.hpp>
#else
# include <memory>
#endif
//-----------------------------------------------------------------------------------------------
// CFileReadCache class definition
......@@ -27,7 +31,11 @@ private:
UINT m_uCacheSize;
UINT m_uCacheStart;
UINT m_uCacheCount;
#if (__cplusplus < 201402L)
boost::shared_array<BYTE> m_pItemCache;
#else
std::shared_ptr<BYTE> m_pItemCache;
#endif
private: // Unimplemented default member functions.
// Declare but don't define copy constructors to prevent use of defaults.
......
......@@ -16,6 +16,8 @@
#include "../axon/AxAbfFio32/filedesc.hpp"
#if (__cplusplus < 201103)
#include <boost/shared_ptr.hpp>
#else
#include <memory>
#endif
//===============================================================================================
......
This diff is collapsed.
......@@ -98,11 +98,7 @@ stfio::findType(const std::string& ext) {
else if (ext=="*.tdms") return stfio::tdms;
else if (ext=="*.clp") return stfio::intan;
#if (defined(WITH_BIOSIG) || defined(WITH_BIOSIG2))
# if (BIOSIG_VERSION < 10800)
else if (ext=="*.dat;*.cfs;*.gdf;*.ibw") return stfio::biosig;
# else
else if (ext=="*.dat;*.cfs;*.gdf;*.ibw;*.wcp") return stfio::biosig;
# endif
else if (ext=="*.*") return stfio::biosig;
#endif
else return stfio::none;
......
......@@ -25,7 +25,12 @@
#define _STFIO_H_
#include <iostream>
#include <boost/function.hpp>
#if (__cplusplus < 201103)
# include <boost/function.hpp>
#else
# include <algorithm>
# include <functional>
#endif
#include <vector>
#include <deque>
#include <map>
......
......@@ -191,7 +191,7 @@ double stfnum::lmFit( const Vector_double& data, double dt,
constrains_lm_ub[n_p] = DBL_MAX;
}
if ( can_scale ) {
if (fitFunc.pInfo[n_p].scale == stfnum::noscale) {
if (!fitFunc.pInfo[n_p].scale) {
can_scale = false;
}
}
......
......@@ -33,7 +33,15 @@
#include <vector>
#include <complex>
#include <deque>
#include <boost/function.hpp>
#if (__cplusplus < 201103)
# include <boost/function.hpp>
#else
# include <algorithm>
# include <cassert>
# include <functional>
#endif
#ifdef _OPENMP
#include <omp.h>
#endif
......@@ -42,8 +50,8 @@
#ifdef _MSC_VER
#define INFINITY (DBL_MAX+DBL_MAX)
#ifndef NAN
static const unsigned long __nan[2] = {0xffffffff, 0x7fffffff};
#define NAN (*(const float *) __nan)
static const unsigned long __nan[2] = {0xffffffff, 0x7fffffff};
#define NAN (*(const float *) __nan)
#endif
#endif
......@@ -61,6 +69,8 @@ namespace stfnum {
* that takes a double (the x-value) and a vector of parameters and returns
* the function's result (the y-value).
*/
#if (__cplusplus < 201103)
typedef boost::function<double(double, const Vector_double&)> Func;
//! The jacobian of a stfnum::Func.
......@@ -69,6 +79,17 @@ typedef boost::function<Vector_double(double, const Vector_double&)> Jac;
//! Scaling function for fit parameters
typedef boost::function<double(double, double, double, double, double)> Scale;
#else
typedef std::function<double(double, const Vector_double&)> Func;
//! The jacobian of a stfnum::Func.
typedef std::function<Vector_double(double, const Vector_double&)> Jac;
//! Scaling function for fit parameters
typedef std::function<double(double, double, double, double, double)> Scale;
#endif
//! Dummy function, serves as a placeholder to initialize functions without a Jacobian.
Vector_double nojac( double x, const Vector_double& p);
......@@ -203,16 +224,29 @@ private:
std::vector< std::string > colLabels;
};
#if (__cplusplus < 201103)
//! Print the output of a fit into a stfnum::Table.
typedef boost::function<Table(const Vector_double&,const std::vector<stfnum::parInfo>,double)> Output;
//! Default fit output function, constructing a stfnum::Table from the parameters, their description and chisqr.
Table defaultOutput(const Vector_double& pars,
Table defaultOutput(const Vector_double& pars,
const std::vector<parInfo>& parsInfo,
double chisqr);
//! Initialising function for the parameters in stfnum::Func to start a fit.
typedef boost::function<void(const Vector_double&, double, double, double, double, double, Vector_double&)> Init;
#else
//! Print the output of a fit into a stfnum::Table.
typedef std::function<Table(const Vector_double&,const std::vector<stfnum::parInfo>,double)> Output;
//! Default fit output function, constructing a stfnum::Table from the parameters, their description and chisqr.
Table defaultOutput(const Vector_double& pars,
const std::vector<parInfo>& parsInfo,
double chisqr);
//! Initialising function for the parameters in stfnum::Func to start a fit.
typedef std::function<void(const Vector_double&, double, double, double, double, double, Vector_double&)> Init;
#endif
//! Function used for least-squares fitting.
/*! Objects of this class are used for fitting functions
......
......@@ -76,6 +76,8 @@ stfio::filetype gettype(const std::string& ftype) {
stftype = stfio::igor;
} else if (ftype == "tdms") {
stftype = stfio::tdms;
} else if (ftype == "intan") {
stftype = stfio::intan;
} else {
stftype = stfio::none;
}
......
......@@ -431,7 +431,8 @@ filetype = {
'.abf':'abf',
'.atf':'atf',
'.axgd':'axg',
'.axgx':'axg'}
'.axgx':'axg',
'.clp':'intan'}
def read(fname, ftype=None, verbose=False):
"""Reads a file and returns a Recording object.
......@@ -446,6 +447,7 @@ def read(fname, ftype=None, verbose=False):
"atf" - Axon text file
"axg" - Axograph X binary file
"heka" - HEKA binary file
"intan" - INTAN clamp binary file
if ftype is None (default), it will be guessed from the
extension.
#else
......
......@@ -19,7 +19,10 @@ HAS_MPL = True
try:
import matplotlib
import matplotlib.pyplot as plt
from mpl_toolkits.axes_grid.axislines import Subplot
if (float(matplotlib.__version__[0:3]) > 2.1):
from mpl_toolkits.axisartist import Subplot
else:
from mpl_toolkits.axes_grid.axislines import Subplot
except ImportError as err:
HAS_MPL = False
MPL_ERR = err
......
......@@ -170,11 +170,7 @@ bool wxStfApp::OnInit(void)
#endif
#if (defined(WITH_BIOSIG) || defined(WITH_BIOSIG2))
m_biosigTemplate=new wxDocTemplate( docManager,
# if (BIOSIG_VERSION < 10800)
wxT("Biosig files"), wxT("*.dat;*.cfs;*.gdf;*.ibw"), wxT(""), wxT(""),
# else
wxT("Biosig files"), wxT("*.dat;*.cfs;*.gdf;*.ibw;*.wcp"), wxT(""), wxT(""),
# endif
wxT("Biosig Document"), wxT("Biosig View"), CLASSINFO(wxStfDoc),
CLASSINFO(wxStfView) );
#endif
......
......@@ -80,9 +80,7 @@ wxStfConvertDlg::wxStfConvertDlg(wxWindow* parent, int id, wxString title, wxPoi
myextensions.Add(wxT("ASCII [*.* ]"));
myextensions.Add(wxT("HDF5 [*.h5 ]"));
myextensions.Add(wxT("HEKA files [*.dat ]"));
#if (BIOSIG_VERSION >= 10404)
myextensions.Add(wxT("Igor files [*.ibw ]"));
#endif
wxComboBox* myComboBoxExt;
myComboBoxExt = new wxComboBox(this, wxCOMBOBOX_SRC, myextensions[0],
......@@ -241,11 +239,9 @@ void wxStfConvertDlg::OnComboBoxSrcExt(wxCommandEvent& event){
case 6:
srcFilterExt = stfio::heka;
break;
#if (BIOSIG_VERSION >= 10404)
case 7:
srcFilterExt = stfio::igor;
break;
#endif
default:
srcFilterExt = stfio::none;
}
......
......@@ -655,7 +655,7 @@ bool wxStfDoc::LoadTDMS(const std::string& filename, Recording& ReturnData) {
PyObject* data_list = PyTuple_GetItem(stf_tdms_res, 0);
PyObject* py_dt = PyTuple_GetItem(stf_tdms_res, 1);
double dt = PyFloat_AsDouble(py_dt);
Py_DECREF(py_dt);
// Py_DECREF(py_dt);
Py_ssize_t nchannels = PyList_Size(data_list);
ReturnData.resize(nchannels);
......@@ -673,15 +673,15 @@ bool wxStfDoc::LoadTDMS(const std::string& filename, Recording& ReturnData) {
double* data = (double*)PyArray_DATA(np_array);
std::copy(&data[0], &data[nsamples], &sec.get_w()[0]);
ch.InsertSection(sec, ns);
Py_DECREF(np_array);
// Py_DECREF(np_array);
}
ReturnData.InsertChannel(ch, nc);
nchannels_nonempty++;
}
Py_DECREF(section_list);
// Py_DECREF(section_list);
}
Py_DECREF(data_list);
Py_DECREF(stf_tdms_res);
// Py_DECREF(data_list);
// Py_DECREF(stf_tdms_res);
ReturnData.resize(nchannels_nonempty);
ReturnData.SetXScale(dt);
wxPyEndBlockThreads(blocked);
......
......@@ -27,6 +27,9 @@
#ifndef _WINDOWS
#if (__cplusplus < 201103)
#include <boost/function.hpp>
#else
#include <algorithm>
#include <memory>
#endif
#endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment