Skip to content

Conversation

@jokasimr
Copy link
Contributor

@jokasimr jokasimr commented Nov 5, 2025

Fixes #201

import scipp as sc


def dspacing_peak_positions_from_cif(cif, intensity_threshold=None) -> sc.Variable:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a docstring? In particular, it needs to explain the cif argument because it is not clear what types are allowed and what kinds of strings can be passed.


d = dspacing_peak_positions_from_cif(
'codid::9011998',
sc.scalar(50, unit='1e10'),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this strange unit instead of sc.scalar(1e10)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I want to test that the unit conversion is done.

jokasimr and others added 3 commits November 5, 2025 16:29
@jokasimr jokasimr requested a review from jl-wynen November 6, 2025 13:59
@jokasimr jokasimr merged commit d60e080 into main Nov 6, 2025
4 checks passed
@jokasimr jokasimr deleted the peaks-from-cif branch November 6, 2025 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Requirement] Calculate peak positions from CIF

3 participants