pixano.data.dataset.dataset_stat
DatasetStat(**data)
Bases: BaseModel
DatasetStat
Attributes:
Name | Type | Description |
---|---|---|
name |
str
|
Stats name |
type |
str
|
Stats type ('numerical' or 'categorical') |
histogram |
str
|
Stats histogram data |
Raises ValidationError
if the input data cannot be
validated to form a valid model.
self
is explicitly positional-only to allow self
as a field name.
Source code in pydantic/main.py
from_json(json_fp)
staticmethod
Read list of DatasetStats from JSON file
Parameters:
Name | Type | Description | Default |
---|---|---|---|
json_fp
|
Path | S3Path
|
JSON file path |
required |
Returns:
Type | Description |
---|---|
list[DatasetStats]
|
List of DatasetStat |
Source code in pixano/data/dataset/dataset_stat.py
save(save_dir)
Save DatasetInfo to json file replace existing histogram with same name in json_fp
Parameters:
Name | Type | Description | Default |
---|---|---|---|
save_dir
|
Path | S3Path
|
Save directory |
required |