Skip to content

Commit 838e6b6

Browse files
committed
Minor formatting
1 parent 1bb48ec commit 838e6b6

File tree

3 files changed

+11
-12
lines changed

3 files changed

+11
-12
lines changed

spectral_connectivity/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# flake8: noqa
2-
from .transforms import Multitaper
32
from .connectivity import Connectivity
3+
from .transforms import Multitaper

spectral_connectivity/connectivity.py

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
1-
from functools import partial, wraps, lru_cache
1+
from functools import lru_cache, partial, wraps
22
from inspect import signature
33
from itertools import combinations
44

55
import numpy as np
6+
from scipy.fftpack import ifft
67
from scipy.ndimage import label
78
from scipy.stats.mstats import linregress
8-
from scipy.fftpack import ifft
99

1010
from .minimum_phase_decomposition import minimum_phase_decomposition
11-
from .statistics import (adjust_for_multiple_comparisons,
12-
fisher_z_transform,
13-
get_normal_distribution_p_values, coherence_bias)
11+
from .statistics import (adjust_for_multiple_comparisons, coherence_bias,
12+
fisher_z_transform, get_normal_distribution_p_values)
1413

1514
EXPECTATION = {
1615
'trials': partial(np.mean, axis=1),
@@ -625,7 +624,7 @@ def generalized_partial_directed_coherence(self):
625624
return _squared_magnitude(
626625
self._MVAR_Fourier_coefficients /
627626
np.sqrt(noise_variance) / _total_outflow(
628-
self._MVAR_Fourier_coefficients, noise_variance))
627+
self._MVAR_Fourier_coefficients, noise_variance))
629628

630629
def direct_directed_transfer_function(self):
631630
'''A combination of the directed transfer function estimate of
@@ -710,20 +709,20 @@ def _linear_regression(response):
710709
slope = np.full(new_shape, np.nan)
711710
slope[..., signal_combination_ind[:, 0],
712711
signal_combination_ind[:, 1]] = np.array(
713-
regression_results[..., 0, :], dtype=np.float)
712+
regression_results[..., 0, :], dtype=np.float)
714713
slope[..., signal_combination_ind[:, 1],
715714
signal_combination_ind[:, 0]] = -1 * np.array(
716-
regression_results[..., 0, :], dtype=np.float)
715+
regression_results[..., 0, :], dtype=np.float)
717716

718717
delay = slope / (2 * np.pi)
719718

720719
r_value = np.ones(new_shape)
721720
r_value[..., signal_combination_ind[:, 0],
722721
signal_combination_ind[:, 1]] = np.array(
723-
regression_results[..., 2, :], dtype=np.float)
722+
regression_results[..., 2, :], dtype=np.float)
724723
r_value[..., signal_combination_ind[:, 1],
725724
signal_combination_ind[:, 0]] = np.array(
726-
regression_results[..., 2, :], dtype=np.float)
725+
regression_results[..., 2, :], dtype=np.float)
727726
return delay, slope, r_value
728727

729728
def delay(self, frequencies_of_interest=None,

spectral_connectivity/transforms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ def _find_tapers_from_interpolation(
492492

493493
return [_interpolate_taper(
494494
taper, interp_kind, n_time_samples_per_window)
495-
for taper in smaller_tapers]
495+
for taper in smaller_tapers]
496496

497497

498498
def _interpolate_taper(taper, interp_kind, n_time_samples_per_window):

0 commit comments

Comments
 (0)