Skip to content

Commit

Permalink
Lint and isort
Browse files Browse the repository at this point in the history
  • Loading branch information
joeyshuttleworth committed Jun 27, 2024
1 parent c1a52d9 commit f51493f
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions pcpostprocess/detect_ramp_bounds.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import numpy as np


def detect_ramp_bounds(times, voltage_sections, ramp_no=0):
"""
Extract the the times at the start and end of the nth ramp in the protocol.
Expand Down
7 changes: 3 additions & 4 deletions pcpostprocess/subtraction_plots.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
import logging

import numpy as np
from . leak_correct import fit_linear_leak
from matplotlib.gridspec import GridSpec

from .leak_correct import fit_linear_leak


def setup_subtraction_grid(fig, nsweeps):
# Use 5 x 2 grid when there are 2 sweeps
Expand Down Expand Up @@ -53,7 +52,7 @@ def do_subtraction_plot(fig, times, sweeps, before_currents, after_currents,
all_leak_params_before.append(before_params)

after_params, _ = fit_linear_leak(before_currents, voltages, times,
*ramp_bounds)
*ramp_bounds)
all_leak_params_after.append(after_params)

# Compute and store leak currents
Expand Down
1 change: 1 addition & 0 deletions scripts/run_herg_qc.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
from syncropatch_export.trace import Trace
from syncropatch_export.voltage_protocols import VoltageProtocol

from pcpostprocess.detect_ramp_bounds import detect_ramp_bounds
from pcpostprocess.hergQC import hERGQC
from pcpostprocess.infer_reversal import infer_reversal_potential
from pcpostprocess.leak_correct import fit_linear_leak, get_leak_corrected
Expand Down
4 changes: 2 additions & 2 deletions tests/test_subtraction_plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@
import unittest

import matplotlib.pyplot as plt

from syncropatch_export.trace import Trace

from pcpostprocess.subtraction_plots import do_subtraction_plot
from pcpostprocess.detect_ramp_bounds import detect_ramp_bounds
from pcpostprocess.subtraction_plots import do_subtraction_plot


class TestSubtractionPlots(unittest.TestCase):
Expand Down Expand Up @@ -44,5 +43,6 @@ def test_do_subtraction_plot(self):
do_subtraction_plot(fig, times, sweeps, before_current, after_current,
voltages, ramp_bounds, well=well)


if __name__ == "__main__":
pass

0 comments on commit f51493f

Please sign in to comment.