From 603486e8241a6c6c0a8f020b9959523214528e5b Mon Sep 17 00:00:00 2001 From: allevitan Date: Tue, 24 Mar 2026 16:55:56 +0100 Subject: [PATCH] Change the default colormap for exponentiated objects to match that for un-exponentiated objects, and also update test_fancy_ptycho to show all the plots (not just plot level 2) --- src/cdtools/models/fancy_ptycho.py | 7 +++++-- tests/models/test_fancy_ptycho.py | 3 ++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/cdtools/models/fancy_ptycho.py b/src/cdtools/models/fancy_ptycho.py index b363591..58f4f2a 100644 --- a/src/cdtools/models/fancy_ptycho.py +++ b/src/cdtools/models/fancy_ptycho.py @@ -1004,7 +1004,8 @@ class FancyPtycho(CDIModel): basis=self.obj_basis, additional_axis_labels=['Mode #',], units=self.units, - cmap='cividis'), + cmap='cividis', + ), 'condition': lambda self: self.exponentiate_obj, }, { @@ -1015,7 +1016,9 @@ class FancyPtycho(CDIModel): fig=fig, basis=self.obj_basis, additional_axis_labels=['Mode #',], - units=self.units), + units=self.units, + cmap='viridis_r', + ), 'condition': lambda self: self.exponentiate_obj, }, { diff --git a/tests/models/test_fancy_ptycho.py b/tests/models/test_fancy_ptycho.py index 4de9f4a..081d85b 100644 --- a/tests/models/test_fancy_ptycho.py +++ b/tests/models/test_fancy_ptycho.py @@ -69,7 +69,8 @@ def test_lab_ptycho(lab_ptycho_cxi, reconstruction_device, show_plot): units='mm', obj_view_crop=-50, use_qe_mask=True, # test this in the case where no qe mask is defined - panel_plot_mode=True, # test with panel plot mode + panel_plot_mode=True, # test with panel plot mode, + plot_level=4, # test with all plots ) print('Running reconstruction on provided reconstruction_device,',