Original Plan:
~~Wraps initialization in a~~
```python
import ezpz as ez
RANK = ez.get_rank()
cm = ez.profile.get_context_manager(rank=RANK)
with cm:
# Megatron-DeepSpeed init, create model, data loaders, etc.
```
~~see:~~
- ~~[`saforem2/ezpz/src/ezpz/profile.py`](https://github.com/saforem2/ezpz/blob/main/src/ezpz/profile.py)~~
- ~~[\[PR\]: Merge ezpz-profile into main #12](https://github.com/saforem2/ezpz/pull/12#issue-2366943397)~~
~~for additional implementation details~~
Profiling
deepspeed.initialize(...)
Original Plan:
~~Wraps initialization in a~~ ```python import ezpz as ez RANK = ez.get_rank() cm = ez.profile.get_context_manager(rank=RANK) with cm: # Megatron-DeepSpeed init, create model, data loaders, etc. ``` ~~see:~~ - ~~[`saforem2/ezpz/src/ezpz/profile.py`](https://github.com/saforem2/ezpz/blob/main/src/ezpz/profile.py)~~ - ~~[\[PR\]: Merge ezpz-profile into main #12](https://github.com/saforem2/ezpz/pull/12#issue-2366943397)~~ ~~for additional implementation details~~Instead (see discussion):
if running with
PYINSTRUMENT_PROFILER=1
:ezpz.profile.PyInstrumentProfiler
[^ezpz]otherwise:
megatron.utils.Profile
[^ezpz]: From
ezpz.profile