Contents:
from typing import Any from abc import ABC, abstractmethod [docs]class AbstractSimilarity(ABC): [docs] @classmethod @abstractmethod def build(cls, conf: dict): raise NotImplementedError [docs] def __init__(self): pass [docs] @abstractmethod def __call__(self, f: Any, g: Any) -> float: raise NotImplementedError