Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Tags: DCPROGS/SCALCS

Tags

v1.2.0

Toggle v1.2.0's commit message
SCALCS 1.2.0

A minor release rather than a patch, because it corrects computed values as
well as adding API.

Numerical corrections
  - the dARSdS sign: exact_mean_open_shut_time was too large by exactly twice
    the dead time, and the conditional means by once. Checked against eqns
    (121) and (122) of Colquhoun & Hawkes (1995b) and against the mean of the
    asymptotic HJC pdf.
  - qmatlib.H inverted sI - QFF directly, which fails where the asymptotic
    root search walks. The singularity is removable.
  - root bracketing for the asymptotic pdf: counts are recomputed when a bound
    moves, widening repeats, and roots are validated before being returned.

Checked against the Fortran that produced the published results
  - impose_resolution against RESHJC2.FOR, interval for interval.
  - the simulator against Q-matrix theory for multi-state mechanisms.

Structural
  - scsim re-exports burst segmentation from dcio; one implementation in the
    stack rather than two.
  - GPL-2.0-or-later rather than GPL-2.0-only, so that HJCFIT
    (GPL-3.0-or-later) can depend on this.

v1.1.0

Toggle v1.1.0's commit message
SCALCS 1.1.0

First release published to PyPI.

Since 1.0.2:
  - scplotlib renamed to sccurves; it calculates theoretical
    distributions and returns arrays, it does not plot. scalcs.scplotlib
    remains as a deprecation shim.
  - burst segmentation follows the documented DCprogs convention: the
    first defined opening starts a burst, and an unusable interval ends
    the one before it.
  - matplotlib is imported only where a figure is drawn, so the curve
    modules import without it.
  - continuous integration across Linux, macOS and Windows.

v1.0.2

Toggle v1.0.2's commit message
SCALCS 1.0.2

A patch release over 1.0.1, carrying one fix that landed after that tag
was cut, so that the fix is reachable by version rather than only by
commit.

1. The Qt plot window failed to open on modern matplotlib

   Two independent breakages, both from APIs that had moved on since the
   2021 code was written:

   - plotwindow.py imported the Qt4 Agg backend
     (matplotlib.backends.backend_qt4agg), removed in matplotlib 3.5.
     The import raised before any window could be built. It now uses
     backend_qtagg.

   - myqtcommon.py defined a custom square-root axis scale whose
     __init__ called mscale.ScaleBase.__init__(self). Since matplotlib
     3.1 ScaleBase.__init__ takes the axis as an argument, so this
     raised TypeError whenever an axis using the scale was drawn.

   Together these meant the GUI could not display a plot at all on any
   currently supported matplotlib.

   tests/test_gui_plotwindow.py covers both, guarded by importorskip so
   the suite still runs where PyQt is absent.

No API or numerical change: every quantity the library computes is
identical to 1.0.1. Installations that do not use the Qt GUI have no
reason to upgrade.

Verified by installing the built package into a clean virtual
environment and running the suite against it, isolated from any
development checkout: 357 passed, 2 skipped (the PyQt-guarded GUI
tests).

v1.0.1

Toggle v1.0.1's commit message
SCALCS 1.0.1

A patch release over 1.0.0, fixing two defects found while tagging it.

1. Complex results from a real Q matrix on numpy 2.5

   numpy 2.5 changed linalg.eig: for a real matrix whose eigenvalues are
   all real it returns complex128, where 2.4 and earlier returned
   float64. Nothing in the library defended against that, so exp(Qt)
   came back complex - although the exponential of a real generator is
   real by definition - and every quantity derived from it followed.
   It showed as popen.maxPopen returning

       np.complex128(0.953453875851444+0j)

   with 17 ComplexWarnings out of popen.py. The values were right; the
   types were not.

   This affects anyone on a current numpy, which is why it is worth a
   patch release rather than waiting. It is fixed at the source, in
   eigs, eigs_sorted and expQt, which between them have 66 call sites
   across cjumps, firstlatency, scalcslib, scburst and popen. A
   genuinely complex spectrum is still returned complex.

2. Package data missing from the wheel

   scalcs/gui/SCALCS.ICO, scalcs/gui/dca2.gif and
   scalcs/samples/Flip_a1GlyRWT_Burz2004.yaml were not distributed:
   there was no package-data table and no MANIFEST.in. Packaging them
   was not sufficient on its own, because helpmenu.py opened the
   animation as the bare relative path "dca2.gif", which resolves only
   when the process happens to be running in the package directory; it
   is now resolved against the installed package.

Also in this release: the licence is declared as the SPDX expression
GPL-2.0-only in the PEP 639 form, replacing the deprecated identifier
GPL-2.0 given as free text. LICENSE.MD is the GPL version 2 text and no
source file carries an "or later" header, so version 2 only is correct;
this matches the classifier the project already carried, which has been
removed as PEP 639 supersedes it. build-system.requires moves to
setuptools>=77, the first version supporting that form.

Tests: 357 passed, 1 skipped, on both numpy 2.4.6 and 2.5.1 - 348 in
1.0.0 plus the 9 added here. Five of the nine fail against the unfixed
code under numpy 2.5.1.

Verified from a wheel built at this commit and installed into an empty
virtual environment: importlib.metadata and scalcs.version both report
1.0.1; the metadata carries License-Expression: GPL-2.0-only with no
legacy License field and no licence classifier; all three data files are
present; no module resolves outside sys.prefix; and under numpy 2.5.1
expQt returns float64 with maxPopen(tres = 30 us) =
np.float64(0.9534538758514441) and EC50 = 2.3560804576936233e-06.

v1.0.0

Toggle v1.0.0's commit message
SCALCS 1.0.0

First release of the modernise line, and a deliberate break with v0.5.1.

v0.5.1 shipped the class API that came from the refactoring2 branch:
QMatrix, SCBurst, HJCMatrix, AsymptoticPDF, and hjclib.py. 1.0.0 is the
other modernisation of the same 2021 code, developed in parallel and
adopted as the base in PR #7. It is a functional API: qmatlib, scalcslib
and scburst expose module-level functions rather than classes. Code
written against v0.5.1 will not run unchanged.

The reasons for the switch, measured rather than asserted:

  * 348 tests pass here, against 74 on v0.5.1
  * every missed-events Popen calculation raises on v0.5.1 -
    popen.maxPopen and popen.EC50 with tres > 0 both reach for
    qml.GXY, which the class refactor removed from module level -
    and both work here
  * v0.5.1 emitted about 558 KB of stray debug output from a single
    Popen curve; there is none here
  * packaging is correct without patching, and declares only what is
    imported

Also in this release: firstlatency.py (first-latency pdf for a step and
for a concentration pulse), a dataclass jump API in cjumps (SquarePulse,
solve, relaxation_taus), scalcsio delegating to dcio for the modern JSON
format, the GUI moved inside the package as scalcs/gui, and the Sphinx
doc/ tree replaced by Markdown docs/.

The class API is not lost. It is archived on the branch
classapi/refactoring2, and hjclib.py in particular - 1488 lines covering
HJCMatrix, AsymptoticPDF, ExactPDFCalculator and DerivativeCalculator -
is the model for reintroducing a class layer on top of this base, this
time with the 348-test suite underneath it.

Verified for this tag: 348 passed, 1 skipped; a wheel built from this
commit installs into an empty virtual environment with no module
resolving outside sys.prefix; maxPopen and EC50 at tres = 30 us return
0.95345 and 2.3561e-06; GlyR_flip gives Popen(1 mM) = 0.94133; and the
Colquhoun & Lape (2012) reproduction notebook runs against this commit
unchanged, all twelve published values within 0.129 %.

Two known gaps, neither affecting the library:

  * three data files under scalcs/ are not packaged into the wheel
    (gui/SCALCS.ICO, gui/dca2.gif, samples/Flip_a1GlyRWT_Burz2004.yaml);
    no module loads them at import time, and helpmenu.py reads the gif
    by a relative path in any case
  * popen.maxPopen returns np.complex128 rather than a float when
    tres > 0, with ComplexWarnings; the real part is correct

v0.5.1

Toggle v0.5.1's commit message
SCALCS 0.5.1

First tagged release of DCPROGS/SCALCS.

This is the first version that installs correctly: setup.py used
find_packages(where="src") against a repository that has no src/
directory, so `pip install` produced an empty distribution. It is
replaced by PEP 621 metadata in pyproject.toml (PR #4), which also
declares the previously undeclared runtime dependencies Deprecated
and tabulate, corrects the licence metadata to GPL-2.0-only to match
LICENSE.MD, and makes PyQt5 an optional `gui` extra.

Also includes three correctness fixes (PR #5):

  * popen.maxPopen bisection, which returned a value about 2.6 % low
    on non-monotonic Popen curves
  * asymptotic root finding, which overflowed for tres above roughly
    0.7 ms
  * asymptotic root bisection, which looped for ever on mechanisms
    with a single open state

Test suite: 74 passed, 0 failed.

v0.5.1-cl2012

Toggle v0.5.1-cl2012's commit message
SCALCS as used for the Colquhoun & Lape (2012) reproduction

Immutable reference point for the corrigendum to

  Colquhoun, D., and R. Lape. 2012. Allosteric coupling in ligand-gated
  ion channels. J. Gen. Physiol. 140:599-612. doi:10.1085/jgp.201210844

This tag marks the same commit as v0.5.1. It exists so that the
reproduction notebook can cite a version that will never be moved or
re-pointed, independently of any future decision about the v0.5.1
release itself.

The notebook lives at

  https://github.com/DCPROGS/ColquhounLape2012-reproduction

and has been executed end to end against this commit in a clean virtual
environment (Python 3.13, NumPy 2.5.1, SciPy 1.18.0), with no cell
errors and with every scalcs module resolving to the installed package
rather than to a development checkout. All twelve published quantities
it checks are reproduced to within 0.13 %.

archive/wiki

Toggle archive/wiki's commit message
Migrating wiki contents from Google Code