-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Put type definition to new file to avoid cycling imports
- Loading branch information
Showing
6 changed files
with
87 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
from collections.abc import Mapping | ||
from typing import Any | ||
|
||
import torch | ||
|
||
RawDomainGroupT = Mapping[str, Any] | ||
"""Matched raw unimodal data from multiple domains. | ||
Keys of the mapping are domains names.""" | ||
|
||
RawDomainGroupDT = dict[str, Any] | ||
"""Matched raw unimodal data from multiple domains. | ||
Keys of the dict are domains names. | ||
This is a more specific version of `RawDomainGroupT` used in method's outputs.""" | ||
|
||
LatentsDomainGroupT = Mapping[str, torch.Tensor] | ||
"""Matched unimodal latent representations from multiple domains. | ||
Keys of the mapping are domains names.""" | ||
|
||
LatentsDomainGroupDT = dict[str, torch.Tensor] | ||
"""Matched unimodal latent representations from multiple domains. | ||
Keys of the dict are domains names. | ||
This is a more specific version of `LatentsDomainGroupT` used in method's outputs.""" | ||
|
||
LatentsDomainGroupsT = Mapping[frozenset[str], LatentsDomainGroupT] | ||
"""Mapping of `LatentsDomainGroupT`. Keys are frozenset of domains matched in the group. | ||
Each group is independent and contains different data (unpaired).""" | ||
|
||
LatentsDomainGroupsDT = dict[frozenset[str], LatentsDomainGroupDT] | ||
"""Mapping of `LatentsDomainGroupDT`. | ||
Keys are frozenset of domains matched in the group. | ||
Each group is independent and contains different data (unpaired). | ||
This is a more specific version of `LatentsDomainGroupsT` used in method's outputs.""" | ||
|
||
RawDomainGroupsT = Mapping[frozenset[str], RawDomainGroupT] | ||
"""Mapping of `RawDomainGroupT`. Keys are frozenset of domains matched in the group. | ||
Each group is independent and contains different data (unpaired).""" | ||
|
||
RawDomainGroupsDT = dict[frozenset[str], RawDomainGroupDT] | ||
"""Mapping of `RawDomainGroupT`. Keys are frozenset of domains matched in the group. | ||
Each group is independent and contains different data (unpaired). | ||
This is a more specific version of `RawDomainGroupsT` used in method's outputs.""" |