whylogs.core.types

Package Contents

Classes

TypedDataConverter

A class to coerce types on data.

Attributes

__ALL__

class whylogs.core.types.TypedDataConverter

A class to coerce types on data.

To see available types:

>>> from whylogs.core.types.typeddataconverter import TYPES
>>> print("\n".join(sorted(TYPES.keys())))
static convert(data)

Convert data to a typed value

If a data is a string, parse data with yaml. Else, return data unchanged

Note: this method is very slow, since it relies on the complex and python-based implementation of yaml.

static get_type(typed_data)

Extract the data type of a value. See typeddataconvert.TYPES for available types.

Parameters

typed_data – Data processed by TypedDataConverter.convert

Returns

dtype

Return type

TYPES

whylogs.core.types.__ALL__