Skip to content

No TPU devices were found. #6778

@sooftware

Description

@sooftware

Thanks for great framework.
I tried to train with tpu (Google Cloud Platform Environment). I encounter error like this:

kaki_ai@kaki-ins:~/kopite-bot$ python3 train_blender.py
16:14:31 | Overriding opt["no_cuda"] to True (previously: False)
16:14:31 | Loading model with `--beam-block-full-context false`
16:14:31 | loading dictionary from /home/kaki_ai/ParlAI/data/models/blender/blender_90M/model.dict
16:14:31 | num words = 54944
16:14:32 | DEPRECATED: XLM should only be used for backwards compatibility, as it involves a less-stable layernorm operation.
16:14:33 | Total parameters: 87,508,992 (87,508,992 trainable)
16:14:33 | Loading existing model params from /home/kaki_ai/ParlAI/data/models/blender/blender_90M/model
Traceback (most recent call last):
  File "train_blender.py", line 47, in <module>
    val_dataloader=test_loader,
  File "/home/kaki_ai/kopite-bot/training/lightning_base.py", line 135, in fit
    accumulate_grad_batches=self.accumulate_grad_batches,
  File "/opt/conda/lib/python3.7/site-packages/pytorch_lightning/trainer/connectors/env_vars_connector.py", line 39, in insert_env_defaults
    return fn(self, **kwargs)
  File "/opt/conda/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 321, in __init__
    replace_sampler_ddp, deterministic, precision, amp_backend, amp_level, plugins
  File "/opt/conda/lib/python3.7/site-packages/pytorch_lightning/trainer/connectors/accelerator_connector.py", line 91, in __init__
    self.tpu_cores = device_parser.parse_tpu_cores(tpu_cores)
  File "/opt/conda/lib/python3.7/site-packages/pytorch_lightning/utilities/device_parser.py", line 113, in parse_tpu_cores
    raise MisconfigurationException('No TPU devices were found.')
pytorch_lightning.utilities.exceptions.MisconfigurationException: No TPU devices were found.

If you have any doubts, please help me. Thank you!

Metadata

Metadata

Assignees

Labels

bugSomething isn't workinghelp wantedOpen to be worked on

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions