lightning/docs/source-app/levels/intermediate/scripts/debug_app.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
698 B
Python
Raw Normal View History

docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
# app.py
from lightning.app import LightningWork, LightningFlow, LightningApp
from lightning.app.runners import MultiProcessRuntime
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
class TrainComponent(LightningWork):
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
def run(self, x):
print(f'train a model on {x}')
class AnalyzeComponent(LightningWork):
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
def run(self, x):
print(f'analyze model on {x}')
class WorkflowOrchestrator(LightningFlow):
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
def __init__(self) -> None:
super().__init__()
self.train = TrainComponent()
self.analyze = AnalyzeComponent()
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
def run(self):
self.train.run("GPU machine 1")
self.analyze.run("CPU machine 2")
docs updates 1/n (#15473) * docs * docs updates * docs updates * docs updates * docs updates * d * d * d * d * d * d * ?? * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d1 * d * d * d * d * d * d * d * d * d * d * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * new title * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * use OSS template * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * only select from parent * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Update docs/README.md Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com> Co-authored-by: William Falcon <williamfalcon@Williams-MacBook-Pro-2.local> Co-authored-by: William Falcon <williamfalcon@Williams-MBP-2.lan> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Jirka <jirka.borovec@seznam.cz> Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
2022-11-03 14:55:30 +00:00
app = LightningApp(WorkflowOrchestrator())
MultiProcessRuntime(app).dispatch()