Skip to content

Commit

Permalink
Copyright (#1)
Browse files Browse the repository at this point in the history
* update copyright and repo links

* use trusted publisher instead of secrets in pypi workflow

* remove ebrains mirroring workflow

* fix isi log slope tests with numpy 2

* use python 3.12 to run cibuildwheel

* use macos-13 with cibuildwheel

---------

Co-authored-by: Aurélien Jaquier
  • Loading branch information
AurelienJaquier authored Jan 28, 2025
1 parent 3880fb0 commit 36797f7
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 42 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, macos-12, windows-latest]
os: [ubuntu-22.04, macos-13, windows-latest]
python: [cp39, cp310, cp311, cp312]
arch: [x86_64, amd64]
exclude:
- os: macos-12
- os: macos-13
arch: amd64
- os: ubuntu-22.04
arch: amd64
Expand All @@ -30,7 +30,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9 # This might need to be dynamic based on the matrix
python-version: 3.12 # This might need to be dynamic based on the matrix
- name: Install cibuildwheel
run: pip install cibuildwheel
- name: Build wheels
Expand Down
24 changes: 0 additions & 24 deletions .github/workflows/mirror-ebrains.yml

This file was deleted.

8 changes: 5 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@ jobs:
name: Release and Publish on PyPI
runs-on: ubuntu-22.04
needs: [call-test-workflow, tag, wheels, tarball]
environment: # needed for pypi publication
name: pypi
url: https://pypi.org/p/efel
permissions: # needed for pypi publication
id-token: write
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -97,6 +102,3 @@ jobs:
- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_PASSWORD }}
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<img src="https://raw.githubusercontent.com/BlueBrain/eFEL/master/docs/source/logo/eFELBanner.png" alt="eFEL banner" />
<img src="https://raw.githubusercontent.com/openbraininstitute/eFEL/master/docs/source/logo/eFELBanner.png" alt="eFEL banner" />

<table>
<tr>
Expand All @@ -20,31 +20,31 @@
<tr>
<td>License</td>
<td>
<a href="https://github.com/BlueBrain/efel/blob/master/LICENSE.txt">
<a href="https://github.com/openbraininstitute/efel/blob/master/LICENSE.txt">
<img src="https://img.shields.io/pypi/l/efel.svg" alt="license" />
</a>
</td>
</tr>
<tr>
<td>Build Status</td>
<td>
<a href="https://github.com/BlueBrain/eFEL/actions">
<img src="https://github.com/BlueBrain/eFEL/workflows/Build/badge.svg?branch=master" alt="actions build status" />
<a href="https://github.com/openbraininstitute/eFEL/actions">
<img src="https://github.com/openbraininstitute/eFEL/workflows/Build/badge.svg" alt="actions build status" />
</a>
</td>
</tr>
<tr>
<td>Coverage</td>
<td>
<a href="https://codecov.io/gh/BlueBrain/efel">
<img src="https://codecov.io/github/BlueBrain/eFEL/coverage.svg?branch=master" alt="coverage" />
<a href="https://codecov.io/gh/openbraininstitute/efel">
<img src="https://codecov.io/github/openbraininstitute/eFEL/coverage.svg?branch=master" alt="coverage" />
</a>
</td>
</tr>
<tr>
<td>Gitter</td>
<td>
<a href="https://gitter.im/bluebrain/efel">
<a href="https://gitter.im/openbraininstitute/efel">
<img src="https://badges.gitter.im/Join%20Chat.svg" />
</a>
</td>
Expand Down Expand Up @@ -121,7 +121,7 @@ pip install efel
If you want to install straight from the github repository you can use

```bash
pip install git+git://github.com/BlueBrain/eFEL
pip install git+git://github.com/openbraininstitute/eFEL
```

Quick Start
Expand All @@ -139,7 +139,7 @@ To get a list with all the available feature names
efel.get_feature_names()
```

Note that the extra-cellular features, the bpap_attenuation feature and the check_ais_initiation feature are not listed above because they have to be used in a special way, as described [here](https://github.com/BlueBrain/eFEL/blob/master/examples/extracellular/extrafeats_example.ipynb) for extra-cellular features, [here](https://github.com/BlueBrain/eFEL/blob/master/docs/source/eFeatures.rst#bpap_attenuation) for bpap_attenuation feature and [here](https://github.com/BlueBrain/eFEL/blob/master/docs/source/eFeatures.rst#check_ais_initiation) for check_ais_initiation feature.
Note that the extra-cellular features, the bpap_attenuation feature and the check_ais_initiation feature are not listed above because they have to be used in a special way, as described [here](https://github.com/openbraininstitute/eFEL/blob/master/examples/extracellular/extrafeats_example.ipynb) for extra-cellular features, [here](https://github.com/openbraininstitute/eFEL/blob/master/docs/source/eFeatures.rst#bpap_attenuation) for bpap_attenuation feature and [here](https://github.com/openbraininstitute/eFEL/blob/master/docs/source/eFeatures.rst#check_ais_initiation) for check_ais_initiation feature.

To change the spike detection threshold setting (default is -20 mV)

Expand All @@ -151,7 +151,7 @@ For a full list of available settings, please refer to the [Setting class](./efe
The python function to extract features is get_feature_values(...).
Below is a short example on how to use this function. The code and example
trace are available
[here](https://github.com/BlueBrain/eFEL/blob/master/examples/basic/basic_example1.py)
[here](https://github.com/openbraininstitute/eFEL/blob/master/examples/basic/basic_example1.py)

```python
"""Basic example 1 for eFEL"""
Expand Down Expand Up @@ -239,4 +239,4 @@ This project/research was supported by funding to the Blue Brain Project, a rese
Lausanne (EPFL), from the Swiss government’s ETH Board of the Swiss Federal Institutes of Technology.

Copyright (c) 2009-2024 Blue Brain Project/EPFL

Copyright (c) 2025 Open Brain Institute
3 changes: 2 additions & 1 deletion tests/test_isi.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ def test_ISIs_single_spike():
def test_isi_log_slope_core_exception():
"""Test that _isi_log_slope_core handles np.polyfit raising a LinAlgError."""
# Mock np.polyfit to raise a LinAlgError
tmp = np.polyfit
np.polyfit = MagicMock(side_effect=np.linalg.LinAlgError("Singular matrix"))

# Call _isi_log_slope_core with some dummy data
Expand All @@ -50,7 +51,7 @@ def test_isi_log_slope_core_exception():
assert result is None

# Reset np.polyfit to its original state
np.polyfit = np.lib.polynomial.polyfit
np.polyfit = tmp


class TestRegularISI:
Expand Down

0 comments on commit 36797f7

Please sign in to comment.