Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some type annotations causing failing tests #456

Merged
merged 2 commits into from
Jul 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gpjax/base/module.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ def static_field( # noqa: PLR0913
)


def _inherited_metadata(cls: type) -> Dict[str]:
def _inherited_metadata(cls: type) -> Dict[str, Any]:
meta_data = dict()
for parent_class in cls.mro():
if parent_class is not cls and parent_class is not Module:
Expand Down
7 changes: 5 additions & 2 deletions gpjax/decision_making/utility_functions/thompson_sampling.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@
SinglePointUtilityFunction,
)
from gpjax.decision_making.utils import OBJECTIVE
from gpjax.gps import ConjugatePosterior
from gpjax.gps import (
ConjugatePosterior,
NonConjugatePosterior,
)
from gpjax.typing import KeyArray


Expand Down Expand Up @@ -56,7 +59,7 @@ def __post_init__(self):

def build_utility_function(
self,
posteriors: Mapping[str, ConjugatePosterior],
posteriors: Mapping[str, ConjugatePosterior | NonConjugatePosterior],
datasets: Mapping[str, Dataset],
key: KeyArray,
) -> SinglePointUtilityFunction:
Expand Down
Loading