Commit c2be541f060d5def2851afc5dd71f6c43a603154

Authored by Jürgen Knödlseder
2 parents 77aa3b08 4910214b

Merge branch 'integration' into devel

ChangeLog
1   -2019-12-13
  1 +2020-02-17
2 2  
3 3 * Version 1.7.0 released
4 4 ========================
5 5  
  6 + Adapt show_pull_histogram.py to matplotlib > 3.1.0 (#3156)
6 7 Avoid negative squared standard deviations in cssrcdetect
7 8 Fix log file header repetition in some cscripts (#3066)
8 9 Add Moon constraints to csviscube (#3065)
9 10 Remove response cache before source testing in cttsmap (#2973)
  11 + Add support for Castro plots to csspec (#2938)
10 12 Enabling running of example scripts from objects in memory (#2925)
11 13 Allow using spectral models without "Prefactor" parameter in cssens
12 14 and cstsdist (#1889)
... ...
1 1 New Features and Important Changes in ctools 1.7.0
2 2  
3   -13 December 2019
  3 +17 February 2020
4 4  
5 5  
6 6 Introduction
... ... @@ -265,7 +265,8 @@ computation (#1889).
265 265  
266 266 csspec - Generates Spectral Energy Distribution
267 267 -----------------------------------------------
268   -None
  268 +Support to generate Castro plots was added and the relevant information is
  269 +now sorted in the output FITS file (#2938).
269 270  
270 271  
271 272 cssrcdetect - Detects sources in sky map
... ... @@ -339,6 +340,10 @@ None
339 340  
340 341 Examples
341 342 --------
  343 +In show_pull_histogram.py relpaced the call to mlab.normpdf() by a direct
  344 +computation of the normalisation, so that the code also works for matplotlib
  345 +> 3.1.0 (#3156).
  346 +
342 347 The show_viscube.py script was added to display a visibility cube (#3065).
343 348  
344 349 The example scripts show_butterfly.py, show_spectrum.py, show_residuals.py
... ...
doc/source/admin/release_history/1.7.rst
... ... @@ -17,6 +17,8 @@ In particular, this release provides:
17 17 Bug fixes
18 18 ---------
19 19  
  20 +* [`3156 <https://cta-redmine.irap.omp.eu/issues/3156>`_] -
  21 + Adapt show_pull_histogram.py to matplotlib > 3.1.0
20 22 * Avoid negative squared standard deviations in :ref:`cssrcdetect`
21 23 * [`3066 <https://cta-redmine.irap.omp.eu/issues/3066>`_] -
22 24 Fix log file header repetition in some cscripts
... ... @@ -28,7 +30,9 @@ Improvements
28 30 * [`3065 <https://cta-redmine.irap.omp.eu/issues/3065>`_] -
29 31 Add Moon constraints to :ref:`csviscube`
30 32 * [`2973 <https://cta-redmine.irap.omp.eu/issues/2973>`_] -
31   - Remove response cache before source testing in cttsmap
  33 + Remove response cache before source testing in :ref:`cttsmap`
  34 +* [`2938 <https://cta-redmine.irap.omp.eu/issues/2938>`_] -
  35 + Add support for Castro plots to :ref:`csspec`
32 36 * [`2925 <https://cta-redmine.irap.omp.eu/issues/2925>`_] -
33 37 Enabling running of example scripts from objects in memory
34 38 * [`1889 <https://cta-redmine.irap.omp.eu/issues/1889>`_] -
... ...
examples/show_pull_histogram.py
... ... @@ -22,7 +22,6 @@ import sys
22 22 import cscripts
23 23 try:
24 24 import matplotlib.pyplot as plt
25   - import matplotlib.mlab as mlab
26 25 plt.figure()
27 26 plt.close()
28 27 except (ImportError, RuntimeError):
... ... @@ -61,7 +60,7 @@ def plot_pull_histogram(filename, parname, nbins, plotfile):
61 60 normed=True, facecolor='green')
62 61  
63 62 # Create expected distribution
64   - y = mlab.normpdf(bins, 0.0, 1.0)
  63 + y = np.exp(-0.5*bins*bins) / np.sqrt(2.0*np.pi)
65 64 plt.plot(bins, y, 'r-', linewidth=2)
66 65  
67 66 # Set plot
... ...