From a0dfc74ce4ffa21ef511694529f20ffe8b9852ba Mon Sep 17 00:00:00 2001 From: Antoine Chaffin Date: Mon, 12 Aug 2024 12:47:30 +0000 Subject: [PATCH] Removing unnecessary +1 in the module name --- giga_cherche/models/colbert.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/giga_cherche/models/colbert.py b/giga_cherche/models/colbert.py index 0fb80fd..3f23a2a 100644 --- a/giga_cherche/models/colbert.py +++ b/giga_cherche/models/colbert.py @@ -251,7 +251,7 @@ def __init__( f"The checkpoint does not contain a linear projection layer. Adding one with output dimensions ({hidden_size}, {embedding_size})" ) # Add a linear projection layer to the model in order to project the embeddings to the desired size - self._modules[f"{len(self._modules) + 1}"] = LinearProjection( + self._modules[f"{len(self._modules)}"] = LinearProjection( in_features=hidden_size, out_features=embedding_size, bias=False )