(self, image_embeds)
| 357 | torch.zeros(1, FIRST_LAST_FRAME_CONTEXT_TOKEN_NUMBER, 1280)) |
| 358 | |
| 359 | def forward(self, image_embeds): |
| 360 | if hasattr(self, 'emb_pos'): |
| 361 | bs, n, d = image_embeds.shape |
| 362 | image_embeds = image_embeds.view(-1, 2 * n, d) |
| 363 | image_embeds = image_embeds + self.emb_pos |
| 364 | clip_extra_context_tokens = self.proj(image_embeds) |
| 365 | return clip_extra_context_tokens |
| 366 | |
| 367 | |
| 368 | class WanModel(ModelMixin, ConfigMixin): |
nothing calls this directly
no outgoing calls
no test coverage detected