From 07ce0d849569e234f2d7714d7438dfab29542610 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fran=C3=A7ois=20Fleuret?= Date: Fri, 7 Jul 2023 13:55:08 +0200 Subject: [PATCH] Update. --- tasks.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tasks.py b/tasks.py index affc8cd..3a4a164 100755 --- a/tasks.py +++ b/tasks.py @@ -225,6 +225,10 @@ class PicoCLVR(Task): primer += [primer_descr + " "] * nb_per_primer result = self.tensorize(primer) + fill = result.new_full( + result.size()[:-1] + (self.height * self.width,), self.t_nul + ) + result = torch.cat((result, fill), 1) ar_mask = (result == self.t_nul).long() masked_inplace_autoregression( model, -- 2.39.5