Skip to content

Commit

Permalink
Merge branch 'master' into old-fn
Browse files Browse the repository at this point in the history
  • Loading branch information
anilbey authored Oct 18, 2023
2 parents bed0b9f + 8ce1476 commit 5349862
Show file tree
Hide file tree
Showing 27 changed files with 250 additions and 1,851 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
tag:
name: Bump version, push tag and make a release
needs: call-test-workflow
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
permissions:
contents: write
steps:
Expand Down Expand Up @@ -54,13 +54,13 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macos-latest, windows-latest]
os: [ubuntu-22.04, macos-latest, windows-latest]
python: [cp38, cp39, cp310, cp311]
arch: [x86_64, amd64]
exclude:
- os: macos-latest
arch: amd64
- os: ubuntu-20.04
- os: ubuntu-22.04
arch: amd64
- os: windows-latest
arch: x86_64
Expand Down Expand Up @@ -90,7 +90,7 @@ jobs:

tarball:
name: Build tarball
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
needs: [call-test-workflow, tag]
steps:
- uses: actions/checkout@v3
Expand All @@ -111,7 +111,7 @@ jobs:

publish:
name: Release and Publish on PyPI
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
needs: [call-test-workflow, tag, wheels, tarball]
steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/keep-alive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:

keep-workflow-alive:
name: Keep workflow alive
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
with:
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
test:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
Expand All @@ -26,10 +26,11 @@ jobs:
pip install tox tox-gh-actions
- name: Run tox
run: tox # this does not call docs
run: |
tox # this does not call docs
coverage:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ["3.11"]
Expand All @@ -55,7 +56,7 @@ jobs:
with:
fail_ci_if_error: false
docs:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
Expand Down
3 changes: 2 additions & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-20.04
os: ubuntu-22.04
tools:
python: "3.9"

Expand All @@ -16,6 +16,7 @@ python:
install:
- method: pip
path: .
- requirements: requirements_docs.txt

# Build documentation in the docs/ directory with Sphinx
sphinx:
Expand Down
13 changes: 10 additions & 3 deletions efel/cppcore/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,22 @@
# along with this library; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.

cmake_minimum_required(VERSION 2.6)
cmake_minimum_required(VERSION 3.12)

# Set C++ standard
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)

set(CMAKE_BUILD_TYPE Debug)

set(FEATURESRCS Utils.cpp LibV1.cpp LibV2.cpp LibV3.cpp LibV4.cpp LibV5.cpp
set(FEATURESRCS Utils.cpp LibV1.cpp LibV2.cpp LibV3.cpp LibV5.cpp
FillFptrTable.cpp DependencyTree.cpp efel.cpp cfeature.cpp
mapoperations.cpp)

set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra")


add_library(efelStatic ${FEATURESRCS})
set_target_properties(efelStatic PROPERTIES OUTPUT_NAME efel)
Expand All @@ -33,6 +40,6 @@ add_library(efel SHARED ${FEATURESRCS})
install(TARGETS efel LIBRARY DESTINATION lib)

install(FILES efel.h cfeature.h FillFptrTable.h LibV1.h LibV2.h LibV3.h
LibV4.h LibV5.h mapoperations.h Utils.h DependencyTree.h eFELLogger.h
LibV5.h mapoperations.h Utils.h DependencyTree.h eFELLogger.h
types.h
DESTINATION include)
21 changes: 0 additions & 21 deletions efel/cppcore/FillFptrTable.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,17 @@
int FillFptrTable() {
//****************** for FptrTableV1 *****************************
FptrTableV1["interpolate"] = &LibV1::interpolate;
FptrTableV1["peak_indices"] = &LibV1::peak_indices;
FptrTableV1["ISI_values"] = &LibV1::ISI_values;
FptrTableV1["peak_voltage"] = &LibV1::peak_voltage;
FptrTableV1["mean_frequency"] = &LibV1::firing_rate;
FptrTableV1["peak_time"] = &LibV1::peak_time;
FptrTableV1["time_to_first_spike"] = &LibV1::first_spike_time;
FptrTableV1["min_AHP_indices"] = &LibV1::min_AHP_indices;
FptrTableV1["min_AHP_values"] = &LibV1::min_AHP_values;
FptrTableV1["voltage_base"] = &LibV1::rest_voltage_value;
FptrTableV1["burst_ISI_indices"] = &LibV1::burst_ISI_indices;
FptrTableV1["adaptation_index"] = &LibV1::adaptation_index;
FptrTableV1["trace_check"] = &LibV1::trace_check;
FptrTableV1["spike_half_width"] = &LibV1::spike_width1;
FptrTableV1["spike_width2"] = &LibV1::spike_width2;
FptrTableV1["burst_mean_freq"] = &LibV1::burst_mean_freq;
FptrTableV1["interburst_voltage"] = &LibV1::interburst_voltage;
FptrTableV1["AHP_depth_abs"] = &LibV1::AHP_depth_abs;
// passive properties
FptrTableV1["time_constant"] = &LibV1::time_constant;
FptrTableV1["voltage_deflection"] = &LibV1::voltage_deflection;
Expand Down Expand Up @@ -65,17 +59,9 @@ int FillFptrTable() {

//****************** for FptrTableV2 *****************************
/*
FptrTableV2["peak_indices"] = &LibV2::peak_indices;
FptrTableV2["ISI_values"] = &LibV2::ISI_values;
FptrTableV2["peak_voltage"] = &LibV2::peak_voltage;
FptrTableV2["firing_rate"] = &LibV2::firing_rate;
FptrTableV2["peak_time"] = &LibV2::peak_time;
FptrTableV2["first_spike_time"] = &LibV2::first_spike_time;
FptrTableV2["AHP_min_indices"] = &LibV2::AHP_min_indices;
FptrTableV2["AHP_values"] = &LibV2::AHP_values;
FptrTableV2["rest_voltage_value"] = &LibV2::rest_voltage_value;
FptrTableV2["burst_vector"] = &LibV2::burst_vector;
FptrTableV2["adaptation_index"] = &LibV2::adaptation_index;
*/

// AP parameter
Expand Down Expand Up @@ -137,18 +123,11 @@ int FillFptrTable() {
//****************** end of FptrTableV2 *****************************

//****************** FptrTableV3 *****************************
FptrTableV3["AP_amplitude"] = &LibV3::AP_amplitude;
FptrTableV3["AP_width"] = &LibV3::AP_width;

FptrTableV3["AP_begin_indices"] = &LibV3::AP_begin_indices;
FptrTableV3["AP_end_indices"] = &LibV3::AP_end_indices;
// eFeatures
FptrTableV3["depolarized_base"] = &LibV3::depolarized_base;

//****************** end of FptrTableV3 *****************************

FptrTableV4["peak_indices"] = &LibV4::peak_indices;

//****************** FptrTableV5 *****************************

FptrTableV5["ISI_log_slope"] = &LibV5::ISI_log_slope;
Expand Down
2 changes: 0 additions & 2 deletions efel/cppcore/FillFptrTable.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,11 @@
#include "LibV1.h"
#include "LibV2.h"
#include "LibV3.h"
#include "LibV4.h"
#include "LibV5.h"

extern feature2function FptrTableV1;
extern feature2function FptrTableV2;
extern feature2function FptrTableV3;
extern feature2function FptrTableV4;
extern feature2function FptrTableV5;

int FillFptrTable();
Expand Down
Loading

0 comments on commit 5349862

Please sign in to comment.