{% set name = "pytorch-lightning" %}
{% set version = "2.3.0" %}

package:
  name: {{ name|lower }}
  version: {{ version }}

source:
  url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz
  sha256: 89caf90e3543b314508493f26e0eca8d5e10e43e3d9e6c143acd8ddceb584ce2

build:
  number: 0
  skip: True  # [py<37]
  script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation

requirements:
  host:
    - pip
    - python
    - setuptools
    - wheel
  run:
    # Dependencies from pytorch-lightning/requirements/pytorch/base.txt
    - python
    - packaging >=20.0
    - numpy >=1.17.2
    - pyyaml >=5.4
    - pytorch >=2.0.0
    - tqdm >=4.57.0
    - fsspec >=2022.5.0
    - torchmetrics >=0.7.0
    - typing-extensions >=4.4.0
    - lightning-utilities >=0.8.0

test:
  imports:
    - pytorch_lightning
  requires:
    - pip
  commands:
    - pip check

about:
  home: https://lightning.ai/
  summary: PyTorch Lightning is the lightweight PyTorch wrapper for ML researchers. Scale your models. Write less boilerplate.
  license: Apache-2.0
  license_family: Apache
  license_file: LICENSE
  description: |
    Lightning is a way to organize your PyTorch code to decouple the science code from the engineering.
    It's more of a style-guide than a framework.

    In Lightning, you organize your code into 3 distinct categories:

    1. Research code (goes in the LightningModule).
    2. Engineering code (you delete, and is handled by the Trainer).
    3. Non-essential research code (logging, etc. this goes in Callbacks).

    Although your research/production project might start simple, once you add things like GPU AND TPU training,
    16-bit precision, etc, you end up spending more time engineering than researching.
    Lightning automates AND rigorously tests those parts for you.

    Overall, Lightning guarantees rigorously tested, correct, modern best practices for the automated parts.

  doc_url: https://pytorch-lightning.readthedocs.io
  dev_url: https://github.com/Lightning-AI/lightning

extra:
  recipe-maintainers:
    - williamFalcon
    - borda
    - carmocca
