DEV Community

Cover image for Watch out for the (PyTorch) Lightning
Tina Huynh
Tina Huynh

Posted on

4 1

Watch out for the (PyTorch) Lightning

Table of Contents

  1. What is PyTorch Lightning
  2. Installing and Getting Started
  3. Learning with Lighting
  4. Grid AI
  5. Helpful Links

What is PyTorch Lightning

Turn PyTorch code into Lightning code.

PyTorch Code of model:
py model

Lightning Code of model:
lightning model

PyTorch Code of training:
py train

Lightning Code of training:
lightning train

More about PyTorch here:

Back to TOC

Installing and Getting Started

Install PyTorch Lightning by running:

pip install pytorch-lightning
Enter fullscreen mode Exit fullscreen mode

or

conda install pytorch-lightning -c conda-forge
Enter fullscreen mode Exit fullscreen mode

Lighting in 15 Minutes

PyTorch Lighting's documentation has skill levels you are able to walk through, each teaching you a new skill.
Level 1: Train a model
Level 2: Add a validation and test set
Level 3: Use pretrained models
Level 4: Enable script parameters
.
.
Level 10: Understand your model
Level 11: Explore SOTA scaling techniques
.
.
Level 20: Explore HPUs
Level 21: Master TPUs
Level 22: Reach 1 trillion parameters on GPUs
.
.
.
Level 26: Make your own profiler

Learning with Lighting

There are many tutorials and other resources on PyTorch Lighting's website you can utilize to start your journey with Lighting.

Tutorials

Glossary

Common WorkFlows

Slack Community

Join their Slack to ask the community questions and check out the GitHub here.

Grid AI

From the creators of PyTorch Lighting, you can get started with grid and train countless of ML models from your laptop with zero code changes!

Introducing Grid AI

Helpful Links

Happy coding!

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more