Skip to content

Commit 8f5dbde

Browse files
authored
Skip running test_run_experiments.py tests in CI. Reorganized environment files by splitting environment.yml into specific requirement files (e.g., full, streaming, stimpres, docsbuild). Updated installation instructions to align with the new environment structure and clarified differences for macOS arm64. (#287)
* Reorganized environment files by splitting `environment.yml` into specific requirement files (e.g., full, streaming, stimpres, docsbuild). Updated installation instructions to align with the new environment structure and clarified differences for macOS arm64. * Standardize environment naming and update dependency formats Renamed environment files and labels to use a consistent "eeg-expy" prefix. Updated Python dependency to a fixed version (3.8) and added Rust for docs build environments. Adjusted installation instructions and GitHub workflow to align with the new naming conventions. * fixed naming * Fixed typo for filename and made doco clearer and added verbose switch to log to console in realtime * removed * fixed command for intel binaries * fixed the installation steps order
1 parent f887c93 commit 8f5dbde

14 files changed

+109
-30
lines changed

.DS_Store

-8 KB
Binary file not shown.

.github/workflows/test.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -55,21 +55,17 @@ jobs:
5555
- name: Install conda
5656
uses: conda-incubator/setup-miniconda@v3
5757
with:
58-
environment-file: environment.yml
58+
environment-file: environments/eeg-expy-full.yml
5959
auto-activate-base: true
6060
python-version: 3.8
61-
activate-environment: EEG-ExPy
61+
activate-environment: eeg-expy-full
6262
channels: conda-forge
6363
miniconda-version: "latest"
6464
- name: Install dependencies via conda
6565
shell: bash -el {0}
6666
run: |
6767
conda info
68-
conda activate EEG-ExPy
69-
- name: Install dependencies
70-
shell: bash -el {0}
71-
run: |
72-
make build
68+
conda activate eeg-expy-full
7369
- name: Run eegnb install test
7470
shell: bash -el {0}
7571
run: |
@@ -86,7 +82,8 @@ jobs:
8682
Xvfb :0 -screen 0 1024x768x24 -ac +extension GLX +render -noreset &> xvfb.log &
8783
export DISPLAY=:0
8884
fi
89-
make test
85+
make test PYTEST_ARGS="--ignore=tests/test_run_experiments.py"
86+
9087
9188
typecheck:
9289
name: typecheck (${{ matrix.os }}, py-${{ matrix.python_version }})

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ htmlcov
1818
# PyCharm
1919
.idea/
2020

21-
*.DS_Store*
21+
**/.DS_Store

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ install-docs-build-dependencies:
66
pip install -e .[docsbuild]
77

88
test:
9-
pytest
9+
pytest $(PYTEST_ARGS)
1010

1111
typecheck:
1212
# Exclude visual_cueing due to errors

doc/getting_started/installation.rst

Lines changed: 38 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,49 @@ Use the following commands to download the repo, create and activate a conda or
4242

4343
.. tab:: Conda
4444

45-
.. code-block:: bash
45+
.. tabs::
46+
47+
Available environment file options:
48+
49+
- `eeg-expy-full`: Install all dependencies
50+
51+
- `eeg-expy-docsbuild`: Documentation
52+
53+
- `eeg-expy-stimpres`: Stimulus presentation
54+
55+
- `eeg-expy-streaming`: Data streaming
56+
57+
- `eeg-expy-streamstim`: Combined streaming and stimulus presentation
58+
59+
60+
.. tab:: Windows, Linux or MacOS intel
61+
62+
.. code-block:: bash
63+
64+
git clone https://github.com/NeuroTechX/eeg-expy
65+
66+
cd eeg-expy
67+
68+
conda env create -v -f environments/eeg-expy-full.yml
69+
70+
conda activate eeg-expy-full
71+
72+
.. tab:: MacOS arm64(M1, M2, etc.)
4673

47-
conda create -n "eeg-expy" python=3.8 git pip
74+
.. code-block:: bash
4875
49-
conda activate "eeg-expy"
76+
# clone the repo
77+
git clone https://github.com/NeuroTechX/eeg-expy
5078
51-
git clone https://github.com/NeuroTechX/eeg-expy
79+
# navigate to the repo
80+
cd eeg-expy
5281
53-
cd eeg-expy
54-
55-
pip install -e .
82+
# for audio to be supported, osx-64 runtime is currently required,
83+
# drop the '--platform osx-64' parameter if audio is not needed, to use the native runtime.
84+
conda env create -v --platform osx-64 -f environments/eeg-expy-full.yml
5685
86+
# activate the environment
87+
conda activate eeg-expy-full
5788
5889
.. tab:: Virtualenv
5990

doc/getting_started/running_experiments.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,9 @@ print("Recording saved in", experiment.save_fn)
158158

159159
## Using virtual reality
160160

161-
### Heads up display
161+
### Head mounted display
162162

163-
A heads-up display can be used for presenting experiments in a similar way to a monitor, without much modification.
163+
A head mounted display can be used for presenting experiments in a similar way to a monitor, without much modification.
164164

165165
#### Features to be added in future releases:
166166

environment.yml

Lines changed: 0 additions & 6 deletions
This file was deleted.

environments/eeg-expy-docsbuild.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: eeg-expy-docsbuild
2+
channels:
3+
- conda-forge
4+
dependencies:
5+
# System-level dependencies
6+
- python=3.8
7+
- pytables # install pytables for macOS arm64, so do not need to build from source.
8+
- rust # used by docsbuild
9+
- pip
10+
- pip:
11+
# Install package with only Analysis requirements
12+
- -e ..[docsbuild]

environments/eeg-expy-full.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: eeg-expy-full
2+
channels:
3+
- conda-forge
4+
dependencies:
5+
# System-level dependencies
6+
- python=3.8
7+
- pytables # install pytables for macOS arm64, so do not need to build from source.
8+
- rust # used by docsbuild
9+
- liblsl # install liblsl to prevent error on macOS and Ubuntu: "RuntimeError: LSL binary library file was not found."
10+
- wxpython>=4.0 # install wxpython to prevent error on macOS arm64: "site-packages/wx/_core.cpython-38-darwin.so, 0x0002): symbol not found in flat namespace '__ZN10wxBoxSizer20InformFirstDirectionEiii'"
11+
- pip
12+
- pip:
13+
# Install package with only Analysis requirements
14+
- -e ..[full]

environments/eeg-expy-stimpres.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: eeg-expy-stimpres
2+
channels:
3+
- conda-forge
4+
dependencies:
5+
# System-level dependencies
6+
- python=3.8
7+
- wxpython>=4.0 # install wxpython to prevent error on macOS arm64: "site-packages/wx/_core.cpython-38-darwin.so, 0x0002): symbol not found in flat namespace '__ZN10wxBoxSizer20InformFirstDirectionEiii'"
8+
- pip
9+
- pip:
10+
# Install package with Analysis + Streaming requirements
11+
- -e ..[stimpres]

environments/eeg-expy-streaming.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: eeg-expy-streaming
2+
channels:
3+
- conda-forge
4+
dependencies:
5+
# System-level dependencies
6+
- python=3.8
7+
- liblsl # install liblsl to prevent error on macOS and Ubuntu: "RuntimeError: LSL binary library file was not found."
8+
- pip
9+
- pip:
10+
# Install package with Analysis + Streaming requirements
11+
- -e ..[streaming]

environments/eeg-expy-streamstim.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: eeg-expy-streamstim
2+
channels:
3+
- conda-forge
4+
- defaults
5+
dependencies:
6+
# System-level dependencies
7+
- python=3.8
8+
- liblsl # install liblsl to prevent error on macOS and Ubuntu: "RuntimeError: LSL binary library file was not found."
9+
- wxpython>=4.0 # install wxpython to prevent error on macOS arm64: "site-packages/wx/_core.cpython-38-darwin.so, 0x0002): symbol not found in flat namespace '__ZN10wxBoxSizer20InformFirstDirectionEiii'"
10+
- pip
11+
- pip:
12+
# Install package with only Analysis requirements
13+
- -e ..[streamstim]

requirements.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,6 @@ airium>=0.1.0
7070
attrdict>=2.0.1
7171
attrdict3
7272

73-
# This might try to build from source on linux (since there are no wheels for Linux on PyPI) .
74-
# You can pass `--find-links=https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-20.04/` your `pip install` to use the prebuilt wheels at the link.
75-
wxPython>=4.0 ; platform_system == "Linux"
76-
7773
# pywinhook needs some special treatment since there are only wheels on PyPI for Python 3.7-3.8, and building requires special tools (swig, VS C++ tools)
7874
# See issue: https://github.com/NeuroTechX/eeg-notebooks/issues/29
7975
pywinhook>=1.6.0 ; platform_system == "Windows" and (python_version == "3.7" or python_version == "3.8")

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,5 +38,5 @@
3838
"License :: OSI Approved :: MIT License",
3939
"Operating System :: OS Independent",
4040
],
41-
python_requires='>=3.7',
41+
python_requires='>=3.8',
4242
)

0 commit comments

Comments
 (0)