MCPcopy Create free account
hub / github.com/alexrame/fishr / predict

Method predict

domainbed/algorithms.py:726–729  ·  view source on GitHub ↗
(self, x, env=None)

Source from the content-addressed store, hash-verified

724 return return_embedding.view(1, -1).repeat(len(features), 1)
725
726 def predict(self, x, env=None):
727 features = self.featurizer(x)
728 embedding = self.update_embeddings_(features, env).normal_()
729 return self.classifier(torch.cat((features, embedding), 1))
730
731
732class SagNet(Algorithm):

Callers 1

updateMethod · 0.95

Calls 1

update_embeddings_Method · 0.95

Tested by

no test coverage detected