Skip to content

Commit

Permalink
Merge branch 'master' of github.com:facebookresearch/MUSE
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillaume Lample committed Jun 13, 2018
2 parents 7e7599a + f516a9b commit 1cd1f7b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/dico_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def build_dictionary(src_emb, tgt_emb, params, s2t_candidates=None, t2s_candidat
if len(final_pairs) == 0:
logger.warning("Empty intersection ...")
return None
dico = torch.LongTensor(list([[a, b] for (a, b) in final_pairs]))
dico = torch.LongTensor(list([[int(a), int(b)] for (a, b) in final_pairs]))

logger.info('New train dictionary of %i pairs.' % dico.size(0))
return dico.cuda() if params.cuda else dico

0 comments on commit 1cd1f7b

Please sign in to comment.