Skip to content

Commit

Permalink
👌 Renamed 'coherent_artifact_concentration' to 'coherent_artifact_res…
Browse files Browse the repository at this point in the history
…ponse'

Ref: glotaran#808 (comment)
  • Loading branch information
s-weigand committed Sep 11, 2021
1 parent 93223cb commit 08b0aae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ def finalize_data(
global_dimension = dataset_model.get_global_dimension()
model_dimension = dataset_model.get_model_dimension()
dataset.coords["coherent_artifact_order"] = np.arange(1, self.order + 1)
concentration_dimensions = (model_dimension, "coherent_artifact_order")
response_dimensions = (model_dimension, "coherent_artifact_order")
if dataset_model.is_index_dependent() is True:
concentration_dimensions = (global_dimension, *concentration_dimensions)
dataset["coherent_artifact_concentration"] = (
concentration_dimensions,
response_dimensions = (global_dimension, *response_dimensions)
dataset["coherent_artifact_response"] = (
response_dimensions,
dataset.matrix.sel(clp_label=self.compartments()).values,
)
dataset["coherent_artifact_associated_spectra"] = (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,11 @@ def test_coherent_artifact(is_index_dependent: bool):
assert data.data.shape == resultdata.fitted_data.shape
assert np.allclose(data.data, resultdata.fitted_data)

assert "coherent_artifact_concentration" in resultdata
assert "coherent_artifact_response" in resultdata
if is_index_dependent:
assert resultdata["coherent_artifact_concentration"].shape == (spectral.size, time.size, 3)
assert resultdata["coherent_artifact_response"].shape == (spectral.size, time.size, 3)
else:
assert resultdata["coherent_artifact_concentration"].shape == (time.size, 3)
assert resultdata["coherent_artifact_response"].shape == (time.size, 3)

assert "coherent_artifact_associated_spectra" in resultdata
assert resultdata["coherent_artifact_associated_spectra"].shape == (3, 3)

0 comments on commit 08b0aae

Please sign in to comment.