require pydantic

This commit is contained in:
Kashif Rasul
2019-12-01 10:16:07 +01:00
parent 78ebf59d15
commit b036a77b7f
2 changed files with 6 additions and 3 deletions
+5 -3
View File
@@ -1,6 +1,8 @@
from abc import ABC, abstractmethod
from typing import Any, Dict, Iterable, NamedTuple, Sized, List, Optional
from pydantic import BaseModel
DataEntry = Dict[str, Any]
@@ -43,14 +45,14 @@ class Dataset(Sized, Iterable[DataEntry], ABC):
def __len__(self):
pass
class CategoricalFeatureInfo():
class CategoricalFeatureInfo(BaseModel):
name: str
cardinality: str
class BasicFeatureInfo():
class BasicFeatureInfo(BaseModel):
name: str
class MetaData():
class MetaData(BaseModel):
freq: str = None
target: Optional[BasicFeatureInfo] = None
+1
View File
@@ -24,6 +24,7 @@ setup(
'pydantic',
'gin-config',
'absl-py',
'pydantic',
],
test_suite='tests',