It happens that `quantity_value.subsample(sample_vec)` retrieves fewer samples than in `sample_vec`. It is necessary to investigate this further.