Commit c4c4926f authored by skamann's avatar skamann
Browse files

Removed few deprecation warnings.

parent 2e2b9e0a
......@@ -58,7 +58,7 @@ the data into memory yet but just checks whether the file(s) are valid.
Latest Git revision
-------------------
2022/05/21
2022/06/14
"""
import argparse
import importlib
......@@ -78,7 +78,7 @@ from pampelmuse.utils.fits import read_config_from_header
__author__ = "Sebastian Kamann (s.kamann@ljmu.ac.uk)"
__version__ = "1.0"
__revision__ = 20220522
__revision__ = 20220614
logger = logging.getLogger(__name__)
......
"""
fit_array.py
============
Copyright 2013-2021 Sebastian Kamann
Copyright 2013-2022 Sebastian Kamann
This file is part of PampelMuse.
......@@ -57,7 +57,7 @@ parameters are not fitted.
Latest Git revision
-------------------
2022/03/10
2022/06/14
"""
import collections
import contextlib
......@@ -81,7 +81,7 @@ from ..core.coordinates import Transformation
__author__ = "Sebastian Kamann (s.kamann@ljmu.ac.uk)"
__revision__ = 20220310
__revision__ = 20220614
logger = logging.getLogger(__name__)
......@@ -336,7 +336,7 @@ class FitLayer(object):
# check if valid indices for background components were provided
if background_index is None or len(background_index) != self.n_background:
background_index = np.arange(-1, -(self.n_background + 1), -1)
self.fluxes = self.fluxes.append(pd.Series(0., index=background_index))
self.fluxes = pd.concat([self.fluxes, pd.Series(0., index=background_index)])
self.offsets = None
......@@ -1543,7 +1543,7 @@ class FitLayer(object):
else:
logger.warning('Cannot calculate mean of "{0}" because no PSF fit succeeded.'.format(name))
_final[name] = np.nan
final = final.append(_final)
final = pd.concat([final, _final])
# fit coordinate transformation to provided centroid coordinates
if position_parameters is not None and 'xy' not in position_parameters:
......@@ -1562,7 +1562,7 @@ class FitLayer(object):
except IOError:
logging.error('Fit of coordinate transformation failed.')
else:
final = final.append(_final)
final = pd.concat([final, _final])
return final
......
"""
dynamic_plot_canvas.py
======================
Copyright 2013-2020 Sebastian Kamann
Copyright 2013-2022 Sebastian Kamann
This file is part of PampelMuse.
......@@ -39,7 +39,7 @@ top panel, named 'Spectrum Viewer'.
Latest Git revision
-------------------
2020/07/09
2022/06/10
"""
import inspect
import logging
......@@ -55,7 +55,7 @@ matplotlib.pyplot.rcParams["axes.linewidth"] = 1.5
__author__ = "Sebastian Kamann (s.kamann@ljmu.ac.uk)"
__revision__ = 20200709
__revision__ = 20220610
class DynamicPlotCanvas(FigureCanvasQTAgg):
......@@ -109,9 +109,9 @@ class DynamicPlotCanvas(FigureCanvasQTAgg):
# define two selectors for adding a horizontal range to the rectangles or subtracting it.
self.selector = SpanSelector(self.axes, self.on_select, direction='horizontal', useblit=True,
rectprops=dict(facecolor='red', alpha=0.5), button=1)
props=dict(facecolor='red', alpha=0.5), button=1)
self.deselector = SpanSelector(self.axes, self.on_deselect, direction='horizontal', useblit=True,
rectprops=dict(facecolor='0.5', alpha=0.5), button=3)
props=dict(facecolor='0.5', alpha=0.5), button=3)
# prepare structure to hold the set of rectangles that are overplotted on th data.
# to achieve axes units (bottom to top = 0 to 1) in vertical direction and data units (wavelength) in
......
......@@ -11,6 +11,6 @@ setup(
packages=find_packages(),
scripts=['bin/PampelMuse', ],
package_data={'pampelmuse.config': ['data/pampelmuse.json', ], 'pampelmuse.filters': ['data/*', ]},
install_requires=['numpy', 'scipy', 'astropy', 'matplotlib', 'pandas>1.3', 'PyQt5', 'tqdm'],
install_requires=['numpy', 'scipy', 'astropy', 'matplotlib>=3.5', 'pandas>1.3', 'PyQt5', 'tqdm'],
extras_require={'nfm': 'maoppy>=1.5.0'}
)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment