4.4.7. thuner.attribute.utils

General utilities for object attributes.

Functions

read_attribute_csv(filepath[, ...])

Read a CSV file and return a DataFrame.

time_offset()

Convenience function to build a TimeOffset attribute.

pydantic model thuner.attribute.utils.AttributesRecord[source]

Bases: BaseModel

Class for storing attributes recorded during the tracking process

Fields:
Validators:
  • _check_name » all fields

  • _initialize_attributes » all fields

field attribute_options: Attributes [Required]
field attribute_types: dict | None = None
field member_attributes: dict | None = None
field name: str = None
thuner.attribute.utils.read_attribute_csv(filepath, attribute_type=None, columns=None, times=None, dask=False)[source]

Read a CSV file and return a DataFrame.

Parameters:

filepath (str) – Filepath to the CSV file.

Returns:

DataFrame containing the CSV data.

Return type:

pd.DataFrame

thuner.attribute.utils.time_offset()[source]

Convenience function to build a TimeOffset attribute.