Christian-Palmroos/PyOnset: v1.1.0
Fuente:
Zenodo
Enregistré dans:
| Auteurs principaux: | , |
|---|---|
| Format: | Recurso digital |
| Publié: |
Zenodo
2025
|
| Accès en ligne: | |
| Tags: |
Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
|
| _version_ | 1866902221902315520 |
|---|---|
| author | Christian Palmroos Jan Gieseler |
| author_facet | Christian Palmroos Jan Gieseler |
| contents | <h2>What's Changed:</h2> <h3>1.) Changed the definition of the k-parameter in CUSUM function:</h3> <p>$\mathrm{old:} k = \frac{\mu_{d} - \mu}{\sigma(\ln(\mu_{d}) - \ln(\mu))}$</p> <p>$\mathrm{new:} k = \frac{\mu_{d} - \mu}{\sigma(\ln(\mu_{d}) - \ln(\mu))} - \frac{\mu}{\sigma}$</p> <p>The new k is consistent with the classic Poisson-CUSUM k-parameter. Old k caused the method to be too conservative in onset determination with low counting rate data.</p> <h3>2.) Changes to <code>Onset.cusum_onset()</code></h3> <ul> <li>Return type of <code>onset_stats</code> changed from list to dict. The <code>onset_stats_dict</code> contains the background mean, background mean + n*sigma, the k-parameter, the h-parameter, z-standardized intensity values, the cusum function, the onset time and the channel energy string.</li> <li>Greatly improved the diagnostics mode: The new diagnostics mode, enabled with setting the keyword <code>diagnostics=True</code> in <code>cusum_onset()</code>, now displays individual plots for the z-standardized intensity, the cusum function and the parameter space for the k-parameter. The parameter space also displays the current background conditions mapped to this space, an equality line of $\sigma=\mu$ and a Poisson-statistics line $\sigma=\mu^{2}$.</li> </ul> <h3>3.) Added a new method to the <code>Onset</code> class</h3> <p><strong><code>final_onset_plot()</code> accepts the following parameters:</strong></p> <ul> <li><code>channel</code> {int/str} The channel number or name, depending if custom data or not.</li> <li><code>resample</code> {str}, optional Pandas-compatible time string to time-average the intensity displayed on the plot. Default None.</li> <li><code>xlim</code> {tuple,list}, optional A pair of Pandas-compatible datetime strings. Defines the horizontal boundaries of the plot. Default +3/-5 hours of the onset time.</li> <li><code>ylim</code> {tuple,list}, optional A pair of floats or integers. Define the vertical boundaries of the plot. Default is half of the minimum and 1.5 * maximum intensity displayed on the plot.</li> <li><code>show_background</code> {bool}, optional A switch to draw the background on the plot. Default True.</li> <li><code>peak</code> {bool}, optional A switch to mark the maximum intensity in the plot with a vertical blue line, and add it to the legend and the returned dictionary. Default False.</li> <li><code>onset</code> {str}, optional A switch to use either the "mode" or the "median" of the onset analysis as the onset time. Default "mode".</li> <li><code>title</code> {str}, optional A title string for the figure. Default None generates a title from the <code>Onset</code> object's attributes and channel identifier.</li> <li><code>legend_loc</code> {str}, optional Placement for the legend. Either "in" or "out" of the axis frame. Default "out".</li> <li><code>savepath</code> {str}, optional A path to save the figure and csv of results. Default None.</li> <li><code>save</code> {bool}, optional A switch to save the figure and corresponding csv. Default False.</li> <li><code>figname</code> {str}, optional A custom name for the figure and csv if saved. Default None generates the name from the <code>Onset</code> object's attributes and channel identifier.</li> </ul> <p>This method does not run onset determination or other calculation; instead it is used to simply visualize the onset time and the corresponding uncertainty found with the <code>Onset.onset_statistics_per_channel()</code> method.</p> <h3>4.) Updated the example notebooks</h3> <p>The Jupyter notebooks act as a tutorial on how to use PyOnset step-by-step. Old and changed functionality is replaced with up-to-date examples.</p> <h3>5.) Generated notes</h3> <ul> <li>Restructure package to follow updated style by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/3</li> <li>make compatible with python 3.13 by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/4</li> <li>Create dependabot.yml by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/5</li> </ul> <p><strong>Full Changelog</strong>: https://github.com/Christian-Palmroos/PyOnset/compare/1.0.0...1.1.0</p> |
| format | Recurso digital |
| id | zenodo_https___doi_org_10_5281_zenodo_17093650 |
| institution | Zenodo |
| language | |
| publishDate | 2025 |
| publisher | Zenodo |
| record_format | zenodo |
| spellingShingle | Christian-Palmroos/PyOnset: v1.1.0 Christian Palmroos Jan Gieseler <h2>What's Changed:</h2> <h3>1.) Changed the definition of the k-parameter in CUSUM function:</h3> <p>$\mathrm{old:} k = \frac{\mu_{d} - \mu}{\sigma(\ln(\mu_{d}) - \ln(\mu))}$</p> <p>$\mathrm{new:} k = \frac{\mu_{d} - \mu}{\sigma(\ln(\mu_{d}) - \ln(\mu))} - \frac{\mu}{\sigma}$</p> <p>The new k is consistent with the classic Poisson-CUSUM k-parameter. Old k caused the method to be too conservative in onset determination with low counting rate data.</p> <h3>2.) Changes to <code>Onset.cusum_onset()</code></h3> <ul> <li>Return type of <code>onset_stats</code> changed from list to dict. The <code>onset_stats_dict</code> contains the background mean, background mean + n*sigma, the k-parameter, the h-parameter, z-standardized intensity values, the cusum function, the onset time and the channel energy string.</li> <li>Greatly improved the diagnostics mode: The new diagnostics mode, enabled with setting the keyword <code>diagnostics=True</code> in <code>cusum_onset()</code>, now displays individual plots for the z-standardized intensity, the cusum function and the parameter space for the k-parameter. The parameter space also displays the current background conditions mapped to this space, an equality line of $\sigma=\mu$ and a Poisson-statistics line $\sigma=\mu^{2}$.</li> </ul> <h3>3.) Added a new method to the <code>Onset</code> class</h3> <p><strong><code>final_onset_plot()</code> accepts the following parameters:</strong></p> <ul> <li><code>channel</code> {int/str} The channel number or name, depending if custom data or not.</li> <li><code>resample</code> {str}, optional Pandas-compatible time string to time-average the intensity displayed on the plot. Default None.</li> <li><code>xlim</code> {tuple,list}, optional A pair of Pandas-compatible datetime strings. Defines the horizontal boundaries of the plot. Default +3/-5 hours of the onset time.</li> <li><code>ylim</code> {tuple,list}, optional A pair of floats or integers. Define the vertical boundaries of the plot. Default is half of the minimum and 1.5 * maximum intensity displayed on the plot.</li> <li><code>show_background</code> {bool}, optional A switch to draw the background on the plot. Default True.</li> <li><code>peak</code> {bool}, optional A switch to mark the maximum intensity in the plot with a vertical blue line, and add it to the legend and the returned dictionary. Default False.</li> <li><code>onset</code> {str}, optional A switch to use either the "mode" or the "median" of the onset analysis as the onset time. Default "mode".</li> <li><code>title</code> {str}, optional A title string for the figure. Default None generates a title from the <code>Onset</code> object's attributes and channel identifier.</li> <li><code>legend_loc</code> {str}, optional Placement for the legend. Either "in" or "out" of the axis frame. Default "out".</li> <li><code>savepath</code> {str}, optional A path to save the figure and csv of results. Default None.</li> <li><code>save</code> {bool}, optional A switch to save the figure and corresponding csv. Default False.</li> <li><code>figname</code> {str}, optional A custom name for the figure and csv if saved. Default None generates the name from the <code>Onset</code> object's attributes and channel identifier.</li> </ul> <p>This method does not run onset determination or other calculation; instead it is used to simply visualize the onset time and the corresponding uncertainty found with the <code>Onset.onset_statistics_per_channel()</code> method.</p> <h3>4.) Updated the example notebooks</h3> <p>The Jupyter notebooks act as a tutorial on how to use PyOnset step-by-step. Old and changed functionality is replaced with up-to-date examples.</p> <h3>5.) Generated notes</h3> <ul> <li>Restructure package to follow updated style by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/3</li> <li>make compatible with python 3.13 by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/4</li> <li>Create dependabot.yml by @jgieseler in https://github.com/Christian-Palmroos/PyOnset/pull/5</li> </ul> <p><strong>Full Changelog</strong>: https://github.com/Christian-Palmroos/PyOnset/compare/1.0.0...1.1.0</p> |
| title | Christian-Palmroos/PyOnset: v1.1.0 |
| url | https://doi.org/10.5281/zenodo.17093650 |