MCPcopy Create free account
hub / github.com/pytorch/executorch / __init__

Method __init__

examples/models/stable_diffusion/model.py:41–43  ·  view source on GitHub ↗
(self, text_encoder)

Source from the content-addressed store, hash-verified

39 """Wrapper for CLIP text encoder that extracts last_hidden_state"""
40
41 def __init__(self, text_encoder):
42 super().__init__()
43 self.text_encoder = text_encoder
44
45 def forward(self, input_ids):
46 # Call text encoder and extract last_hidden_state

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected