wristpy.core.cli¶
CLI for wristpy.
Functions
|
Run wristpy orchestrator with command line arguments. |
|
Print the current version of wristpy and exit. |
Classes
|
Valid activity metrics for physical activity categorization. |
|
Setting a calibrator class for typer. |
|
Create a collection of name/value pairs. |
|
Setting a nonwear algorithm class for typer. |
|
Valid output file types for saving data. |
- class wristpy.core.cli.ActivityMetric(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
-
Valid activity metrics for physical activity categorization.
- ag_count = 'ag_count'¶
- enmo = 'enmo'¶
- mad = 'mad'¶
- mims = 'mims'¶
- class wristpy.core.cli.Calibrator(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
-
Setting a calibrator class for typer.
This class is used to define the literal types that are allowed for calibration, and parsing the strings for the orchestrator.
- ggir = 'ggir'¶
- gradient = 'gradient'¶
- none = 'none'¶
- class wristpy.core.cli.NonwearAlgorithms(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
-
Setting a nonwear algorithm class for typer.
This class is used to define the literal types that are allowed for nonwear algorithms, and parsing the strings for the orchestrator.
- cta = 'cta'¶
- detach = 'detach'¶
- ggir = 'ggir'¶
- class wristpy.core.cli.OutputFileType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]¶
-
Valid output file types for saving data.
- csv = '.csv'¶
- parquet = '.parquet'¶
- wristpy.core.cli._parse_thresholds(thresholds: list[str]) list[tuple[float, float, float]] [source]¶
Parse the threshold strings into a list of tuples.
- Parameters:
thresholds – List of threshold strings, each containing three space-separated floats.
- Returns:
List of tuple float triplets containing the parsed threshold values.
- Raises:
typer.BadParameter – If any threshold triplet does not contain exactly three floats
typer.BadParameter – If threshold format is invalid or values cannot be parsed.
- wristpy.core.cli.main(input: ~pathlib.Path = <typer.models.ArgumentInfo object>, output: ~pathlib.Path = <typer.models.OptionInfo object>, output_filetype: ~wristpy.core.cli.OutputFileType = <typer.models.OptionInfo object>, calibrator: ~wristpy.core.cli.Calibrator = <typer.models.OptionInfo object>, activity_metric: list[~wristpy.core.cli.ActivityMetric] = <typer.models.OptionInfo object>, thresholds: list[str] = <typer.models.OptionInfo object>, nonwear_algorithm: list[~wristpy.core.cli.NonwearAlgorithms] = <typer.models.OptionInfo object>, epoch_length: int = <typer.models.OptionInfo object>, verbosity: bool = <typer.models.OptionInfo object>, version: bool = <typer.models.OptionInfo object>) None [source]¶
Run wristpy orchestrator with command line arguments.