Skip to content

Setup #1

Description

@componavt

A few more commands are needed to configure the system (Ubuntu 20):

sudo pip3 install cython

When I tried to run the following script

py inflection.py \
	--datapath sample-data/ \
	--L1 adyghe \
	--L2 kabardian \
	--mode train \
	--setting original

I have got the error:

Traceback (most recent call last):
  File "inflection.py", line 1500, in <module>
    trainer, best_acc, best_edd = train_simple_attention_with_tags(inflection_model, MULTIPLY*low_i+high_i, MULTIPLY*low_t+high_t, MULTIPLY*low_o+high_o)
  File "inflection.py", line 1247, in train_simple_attention_with_tags
    loss = inf_model.get_loss(inputs[j], [NULL], inputs[j], lang_ids[j])
  File "inflection.py", line 897, in get_loss
    return self.decode(encoded, encoded_tags, output_sentence, lang_id, weight, tf_prob)
  File "inflection.py", line 489, in decode
    w1dt = w1dt or self.attention_w1 * input_mat
  File "_dynet.pyx", line 1907, in _dynet.Expression.__mul__
NotImplementedError

There is the following solution:

sudo pip3 install git+https://github.com/clab/dynet#egg=dynet

sudo pip3 install -r requirements.txt

P.S. Thank you for sharing this code!

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