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

TypeError: object() takes no parameters using Google Colab #23

Open
liuzzom opened this issue Jan 27, 2021 · 0 comments
Open

TypeError: object() takes no parameters using Google Colab #23

liuzzom opened this issue Jan 27, 2021 · 0 comments

Comments

@liuzzom
Copy link

liuzzom commented Jan 27, 2021

Hi.
I'm trying to run the train code on a Colab notebook, but I get this error

reading instances: 0it [00:00, ?it/s]Reading data
reading instances: 1600it [00:03, 516.73it/s]
reading instances: 200it [00:00, 1148.52it/s]
building vocab:  12%|#1        | 207/1800 [00:00<00:00, 2067.94it/s]Building the vocabulary
building vocab: 100%|##########| 1800/1800 [00:01<00:00, 1705.78it/s]
Building the model
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-10-bdcf140a0b58> in <module>()
    170 
    171 
--> 172 run_training_loop()

1 frames
<ipython-input-10-bdcf140a0b58> in build_data_loaders(train_data, dev_data)
    143     # We need to get the allennlp-specific collate function, which is
    144     # what actually does indexing and batching.
--> 145     train_loader = DataLoader(train_data, batch_size=8, shuffle=True)
    146     dev_loader = DataLoader(dev_data, batch_size=8, shuffle=False)
    147     return train_loader, dev_loader

TypeError: object() takes no parameters

The code is a copy and paste of the train.py file, I only changed the paths of the .tsv files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant