Skip to content

Dimension mismatch when using pretrained vectors #12

@ajallooeian

Description

@ajallooeian

Hi,

I am trying to use the word vectors from here:
https://fasttext.cc/docs/en/crawl-vectors.html

and use pretrainedVectors option to make a classifier.
./fasttext supervised -input some_data.txt -output some_data.txt.model -pretrainedVectors model.bin -dim 300

However I get:

terminate called after throwing an instance of 'std::invalid_argument'
what(): Dimension of pretrained vectors (-1) does not match dimension (300)!
Aborted (core dumped)

or

terminate called after throwing an instance of 'std::invalid_argument'
what(): Dimension of pretrained vectors (-283686952306184) does not match dimension (300)!
Aborted (core dumped)

Content of sample_data.txt is:
__label__a hello
__label__b good
__label__c bad

I appreciate any advice.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions