MCPcopy Create free account
hub / github.com/YesianRohn/TextSSR / forward

Method forward

diffusers/examples/community/fresco_v2v.py:964–974  ·  view source on GitHub ↗
(self, context)

Source from the content-addressed store, hash-verified

962 self.enable_cfattn(attn_mask)
963
964 def forward(self, context):
965 if self.store:
966 self.stored_attn["decoder_attn"].append(context.detach())
967 if self.use_intraattn and len(self.stored_attn["decoder_attn"]) > 0:
968 tmp = self.stored_attn["decoder_attn"][self.index]
969 self.index = self.index + 1
970 if self.index >= len(self.stored_attn["decoder_attn"]):
971 self.index = 0
972 self.disable_store()
973 return tmp
974 return context
975
976 def __call__(self, context):
977 context = self.forward(context)

Callers 1

__call__Method · 0.95

Calls 1

disable_storeMethod · 0.95

Tested by

no test coverage detected