Skip to content

Commit f2240e5

Browse files
Merge pull request #439 from lsst/tickets/SP-1906
SP-1906: backwards compatibility with numpy 1.
2 parents ab59ca0 + 01322f1 commit f2240e5

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

rubin_sim/maf/metrics/base_metric.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ def __init__(
140140
):
141141
# Turn cols into numpy array so we know
142142
# we can iterate over the columns.
143-
self.col_name_arr = np.array(col, copy=None, ndmin=1)
143+
self.col_name_arr = np.array(col, copy=True, ndmin=1)
144144
# To support simple metrics operating on a single column,
145145
# set self.colname
146146
if len(self.col_name_arr) == 1:

rubin_sim/maf/plots/skyproj_plotters.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -335,15 +335,15 @@ def __call__(self, metric_values, slicer, user_plot_dict, fig=None):
335335
# or specified as decorators.
336336
if self.plot_dict["xlabel"] is None:
337337
if "xlabel" not in self.plot_dict["decorations"]:
338-
self.skyproj.set_xlabel("", visible=False)
338+
self.skyproj.ax.set_xlabel("", visible=False)
339339
else:
340-
self.skyproj.set_xlabel(self.plot_dict["xlabel"])
340+
self.skyproj.ax.set_xlabel(self.plot_dict["xlabel"])
341341

342342
if self.plot_dict["ylabel"] is None:
343343
if "ylabel" not in self.plot_dict["decorations"]:
344-
self.skyproj.set_ylabel("", visible=False)
344+
self.skyproj.ax.set_ylabel("", visible=False)
345345
else:
346-
self.skyproj.set_ylabel(self.plot_dict["ylabel"])
346+
self.skyproj.ax.set_ylabel(self.plot_dict["ylabel"])
347347

348348
if self.plot_dict["label"] is not None:
349349
label_kwargs = {}

0 commit comments

Comments
 (0)