From 12ed3200366cd570718dcddcc925fcc9dcfc2f39 Mon Sep 17 00:00:00 2001 From: Nicolas Barascud <10333715+nbara@users.noreply.github.com> Date: Wed, 3 Jun 2020 13:48:44 +0200 Subject: [PATCH 1/4] Trigger github actions on PR --- .github/workflows/pythonpackage.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml index 28017583..b41f675d 100644 --- a/.github/workflows/pythonpackage.yml +++ b/.github/workflows/pythonpackage.yml @@ -4,7 +4,9 @@ on: push: branches-ignore: - 'gh-pages' - + pull_request: + branches: + - master jobs: build: From 483f44598794cbd8d8f907fed6bf35b456c76acd Mon Sep 17 00:00:00 2001 From: Nicolas Barascud <10333715+nbara@users.noreply.github.com> Date: Wed, 3 Jun 2020 13:50:07 +0200 Subject: [PATCH 2/4] Update pythonpackage.yml --- .github/workflows/pythonpackage.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml index b41f675d..742f2b19 100644 --- a/.github/workflows/pythonpackage.yml +++ b/.github/workflows/pythonpackage.yml @@ -2,6 +2,8 @@ name: unit-tests on: push: + branches: + - master branches-ignore: - 'gh-pages' pull_request: From 54785c23bfe91b4fc6370afbaca48d04c0039648 Mon Sep 17 00:00:00 2001 From: Nicolas Barascud <10333715+nbara@users.noreply.github.com> Date: Wed, 3 Jun 2020 14:03:02 +0200 Subject: [PATCH 3/4] Update pythonpackage.yml --- .github/workflows/pythonpackage.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/pythonpackage.yml b/.github/workflows/pythonpackage.yml index 742f2b19..d4b6b34b 100644 --- a/.github/workflows/pythonpackage.yml +++ b/.github/workflows/pythonpackage.yml @@ -4,8 +4,6 @@ on: push: branches: - master - branches-ignore: - - 'gh-pages' pull_request: branches: - master From 8fb5fc9a85fac580f5f1e5b75886c70ee2e282e8 Mon Sep 17 00:00:00 2001 From: nbara <10333715+nbara@users.noreply.github.com> Date: Wed, 3 Jun 2020 14:10:14 +0200 Subject: [PATCH 4/4] pep --- meegkit/star.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/meegkit/star.py b/meegkit/star.py index 5a8b77a7..f4b178d4 100644 --- a/meegkit/star.py +++ b/meegkit/star.py @@ -74,7 +74,7 @@ def star(X, thresh=1, closest=[], depth=1, pca_thresh=1e-15, n_smooth=10, # Phase 1 # ------------------------------------------------------------------------- - # Find time intervals where at least one channel is excentric -> w == 0 + # Find time intervals where at least one channel is eccentric -> w == 0 # Compute covariance on artifact-free data. iter = n_iter @@ -87,7 +87,7 @@ def star(X, thresh=1, closest=[], depth=1, pca_thresh=1e-15, n_smooth=10, # Compute channel data estimated from its neighbours z = _project_channel(X[:, neighbours], c0, ch, neighbours) - # Compute excentricity over time + # Compute eccentricity over time d[:, ch] = _eccentricity(X[:, ch][:, None], z, w, n_smooth).T d[:, ch] = d[:, ch] / thresh @@ -122,7 +122,7 @@ def star(X, thresh=1, closest=[], depth=1, pca_thresh=1e-15, n_smooth=10, d = _eccentricity(X, None, w, n_smooth) rank = np.argsort(d, axis=1)[:, ::-1].astype(float) - rank[np.where(w)[0], :] = np.nan # exclude parts that are not excentric + rank[np.where(w)[0], :] = np.nan # exclude parts that are not eccentric depth = np.min((depth, n_chans - 1)) ww = np.ones(X.shape) @@ -134,7 +134,7 @@ def star(X, thresh=1, closest=[], depth=1, pca_thresh=1e-15, n_smooth=10, for ch in np.arange(n_chans): neighbours = _closest_neighbours(closest, ch, n_chans) - # find samples where channel `ch` is the most excentric + # find samples where channel `ch` is the most eccentric bad_samples = np.where(ch == rank[:, i_depth])[0] if i_depth != 0: # exclude if not very bad bad_samples = np.delete(