diff --git a/src/invert4geom/cross_validation.py b/src/invert4geom/cross_validation.py index adfc5c12..153d7177 100644 --- a/src/invert4geom/cross_validation.py +++ b/src/invert4geom/cross_validation.py @@ -540,13 +540,13 @@ def zref_density_optimal_parameter( raise ValueError(msg) if zref_values is None: - zref = kwargs.get("zref", None) + zref = kwargs.get("zref") if zref is None: msg = "must provide zref_values or zref in kwargs" raise ValueError(msg) zref_values = [zref] elif density_contrast_values is None: - density_contrast = kwargs.get("density_contrast", None) + density_contrast = kwargs.get("density_contrast") if density_contrast is None: msg = "must provide density_contrast_values or density_contrast in kwargs" raise ValueError(msg) diff --git a/src/invert4geom/plotting.py b/src/invert4geom/plotting.py index 26e10267..a55ebda1 100644 --- a/src/invert4geom/plotting.py +++ b/src/invert4geom/plotting.py @@ -1104,7 +1104,7 @@ def show_prism_layers( notebook=True, ) - opacity = kwargs.get("opacity", None) + opacity = kwargs.get("opacity") if isinstance(prisms, xr.Dataset): prisms = [prisms] @@ -1126,7 +1126,7 @@ def show_prism_layers( style=kwargs.get("style", "surface"), show_edges=kwargs.get("show_edges", False), opacity=trans, - scalar_bar_args=kwargs.get("scalar_bar_args", None), + scalar_bar_args=kwargs.get("scalar_bar_args"), ) else: plotter.add_mesh( @@ -1139,7 +1139,7 @@ def show_prism_layers( show_edges=kwargs.get("show_edges", False), log_scale=kwargs.get("log_scale", True), opacity=trans, - scalar_bar_args=kwargs.get("scalar_bar_args", None), + scalar_bar_args=kwargs.get("scalar_bar_args"), ) plotter.set_scale( zscale=kwargs.get("zscale", 75) @@ -1336,7 +1336,7 @@ def plot_stochastic_results( unit = kwargs.get("unit", "m") reverse_cpt = kwargs.get("reverse_cpt", True) label = kwargs.get("label", "ensemble mean") - points_label = kwargs.get("points_label", None) + points_label = kwargs.get("points_label") fig_height = kwargs.get("fig_height", 12) try: diff --git a/tests/test_inversion.py b/tests/test_inversion.py index e1c307e4..55c1aa7e 100644 --- a/tests/test_inversion.py +++ b/tests/test_inversion.py @@ -171,7 +171,7 @@ def dummy_jacobian_square() -> NDArray: ################ -@pytest.mark.use_numba() +@pytest.mark.use_numba def test_grav_column_der_relative_values(): """ test the grav_column_der function @@ -275,7 +275,7 @@ def test_grav_column_der_relative_values(): assert h < a -@pytest.mark.use_numba() +@pytest.mark.use_numba def test_grav_column_der(): """ test the grav_column_der function against a small prism approximation @@ -306,7 +306,7 @@ def test_grav_column_der(): assert dg_z == pytest.approx(hm_dg_z, rel=1e-2) -@pytest.mark.use_numba() +@pytest.mark.use_numba def test_jacobian_annular(): """ test the jacobian_annular function @@ -359,7 +359,7 @@ def test_prism_properties_error(): inversion._prism_properties(prisms_layer, method="wrong_input") -@pytest.mark.use_numba() +@pytest.mark.use_numba def test_jacobian_prism(): """ test the jacobian_prism function @@ -385,7 +385,7 @@ def test_jacobian_prism(): assert jac[:, 0:-3].min() > 0 -@pytest.mark.use_numba() +@pytest.mark.use_numba def test_jacobian(): """ test the jacobian dispatcher function @@ -470,7 +470,7 @@ def test_solver_square_error(): ] -@pytest.mark.use_numba() +@pytest.mark.use_numba @pytest.mark.parametrize("solver_type", solver_types) def test_solver_square(solver_type): """