MCPcopy Create free account
hub / github.com/Monalissaa/DisenDiff / encode_text

Method encode_text

utils/clip_eval.py:27–28  ·  view source on GitHub ↗
(self, tokens: list)

Source from the content-addressed store, hash-verified

25
26 @torch.no_grad()
27 def encode_text(self, tokens: list) -> torch.Tensor:
28 return self.model.encode_text(tokens)
29
30 @torch.no_grad()
31 def encode_images(self, images: torch.Tensor) -> torch.Tensor:

Callers 2

get_text_featuresMethod · 0.95
extract_all_captionsFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected