Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MLLM train on empty corpus fails with error #484

Closed
osma opened this issue Apr 22, 2021 · 0 comments · Fixed by #495
Closed

MLLM train on empty corpus fails with error #484

osma opened this issue Apr 22, 2021 · 0 comments · Fixed by #495
Labels
Milestone

Comments

@osma
Copy link
Member

osma commented Apr 22, 2021

When trying to train MLLM on an empty corpus it fails with this:

  File "/data/Annif/annif/lexical/mllm.py", line 184, in prepare_train
    for candidates in train_x]), np.array(train_y))
  File "<__array_function__ internals>", line 6, in vstack
  File "/data/Annif/venv/lib/python3.6/site-packages/numpy/core/shape_base.py", line 283, in vstack
    return _nx.concatenate(arrs, 0)
  File "<__array_function__ internals>", line 6, in concatenate
ValueError: need at least one array to concatenate

It would be better to show an informative error, similar to the "cannot evaluate empty corpus" message.

@osma osma added the bug label Apr 22, 2021
@osma osma added this to the Short term milestone Apr 22, 2021
@osma osma closed this as completed in #495 Jun 7, 2021
@osma osma modified the milestones: Short term, 0.53 Aug 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant