pyinstrument
π΄Β Call stack profiler for Python. Shows you why your code is slow!
νμΌ νμκΈ°
μ΅μ’ λ²μ λ€μ΄λ‘λ (.zip)- devcontainer.json
- Dockerfile
- reinstall-cmake.sh
- test.yml
- wheels.yml
- dependabot.yml
- build_js_bundle.py
- bump_version.py
- create_demo_data.py
- create_sample_json.py
- serve_docs
- django_template_render-CIkNzFIy.js
- index-BwGBF3cE.js
- index-CCEFeDHu.css
- sympy_calculation-B9Pn_4RL.js
- wikipedia_article_word_count-CGt_pvsZ.js
- index.html
- signature_change.py
- async-context.svg
- screenshot.jpg
- timeline.png
- conf.py
- guide.md
- home.md
- how-it-works.md
- index.md
- Makefile
- reference.md
- template.html
- template_base.html
- __init__.py
- settings.py
- urls.py
- views.py
- .gitignore
- manage.py
- README.md
- django_template_render.py
- sympy_calculation.py
- wikipedia_article_word_count.py
- aiohttp_web_hello.py
- async_example_simple.py
- async_experiment_1.py
- async_experiment_3.py
- busy_wait.py
- c_sort.py
- context_api.py
- falcon_hello.py
- falcon_hello_file.py
- flask_hello.py
- litestar_hello.py
- np_c_function.py
- tbhide_demo.py
- django_template_render.json
- sympy_calculation.json
- wikipedia_article_word_count.json
- DemoApp.svelte
- main.ts
- favicon.png
- CallStackView.svelte
- CogIcon.svelte
- Frame.svelte
- Header.svelte
- Logo.svelte
- TimelineCanvasView.ts
- TimelineCanvasViewTooltip.svelte
- TimelineView.svelte
- ViewOptions.svelte
- ViewOptionsCallStack.svelte
- ViewOptionsTimeline.svelte
- Frame.ts
- FrameGroup.ts
- frameOps.test.ts
- frameOps.ts
- modelUtil.ts
- processors.ts
- Session.ts
- appState.ts
- CanvasView.ts
- color.ts
- dataTypes.ts
- DevicePixelRatioObserver.ts
- settings.ts
- utils.ts
- app.css
- App.svelte
- main.ts
- types.d.ts
- vite-env.d.ts
- .editorconfig
- .gitignore
- index.html
- package-lock.json
- package.json
- svelte.config.js
- tsconfig.json
- tsconfig.node.json
- vite.config.ts
- count_samples.py
- frame_info.py
- interrupt.py
- multi_overhead.py
- overflow.py
- overhead.py
- pyi_floatclock.c
- pyi_floatclock.h
- pyi_shared.h
- pyi_timing_thread.c
- pyi_timing_thread.h
- pyi_timing_thread_python.py
- stat_profile.c
- stat_profile.pyi
- stat_profile_python.py
- types.py
- __init__.py
- _utils.py
- magic.py
- app.css
- app.js
- __init__.py
- base.py
- console.py
- html.py
- jsonrenderer.py
- pstatsrenderer.py
- session.py
- speedscope.py
- __init__.py
- decorator.py
- keypath.py
- __init__.py
- __main__.py
- context_manager.py
- frame.py
- frame_info.py
- frame_ops.py
- middleware.py
- processors.py
- profiler.py
- py.typed
- session.py
- stack_sampler.py
- typing.py
- util.py
- __init__.py
- test_context.py
- test_custom_timer.py
- test_floatclock.py
- test_frame_info.py
- test_setstatprofile.py
- test_threaded.py
- test_timing_thread.py
- util.py
- __init__.py
- conftest.py
- fake_time_util.py
- test_cmdline.py
- test_cmdline_main.py
- test_context_manager.py
- test_django_middleware.py
- test_ipython_magic.py
- test_overflow.py
- test_processors.py
- test_profiler.py
- test_profiler_async.py
- test_pstats_renderer.py
- test_renderers.py
- test_stack_sampler.py
- test_threading.py
- util.py
- .editorconfig
- .gitignore
- .pre-commit-config.yaml
- .readthedocs.yaml
- LICENSE
- MAINTAINERS.md
- MANIFEST.in
- noxfile.py
- pyproject.toml
- README.md
- requirements-dev.txt
- setup.cfg
- setup.py
# μ€μΉ κ°μ΄λ
git clone https://github.com/joerick/pyinstrument
κΉνλΈμμ νλ‘μ νΈ μ½λ μ 체λ₯Ό λ΄ μ»΄ν¨ν°λ‘ λ΄λ €λ°μ΅λλ€.
cd pyinstrument
λ°©κΈ λ΄λ €λ°μ νλ‘μ νΈ ν΄λ μμΌλ‘ μ΄λν©λλ€.
2. 곡μ μ€μΉ μ€ν¬λ¦½νΈ
μ¬μ μΆμ²- Python 3 pip λͺ λ Ήμ΄λ₯Ό μ°λ €λ©΄ Pythonμ΄ νμν©λλ€.
pip install pyinstrument
PyPIμ λ°°ν¬λ ν¨ν€μ§λ₯Ό λ°λ‘ μ€μΉν©λλ€. μμ€ ν΄λ‘ μ΄ νμ μμ΅λλ€.
pip install --upgrade pip
PyPIμ λ°°ν¬λ ν¨ν€μ§λ₯Ό λ°λ‘ μ€μΉν©λλ€. μμ€ ν΄λ‘ μ΄ νμ μμ΅λλ€.
μ΄ λ ν¬μ READMEμ μ ν μ€μ λͺ λ Ήμ΄λ₯Ό κ·Έλλ‘ κ°μ Έμμ΅λλ€.
3. Node.js
μ¬μnpm ci
μ΄ λͺ λ Ήμ΄λ₯Ό ν°λ―Έλμ κ·Έλλ‘ μ λ ₯ν΄ μ€ννμΈμ.
npm run serve
μ΄ λͺ λ Ήμ΄λ₯Ό ν°λ―Έλμ κ·Έλλ‘ μ λ ₯ν΄ μ€ννμΈμ.
μ΄ λ ν¬μ READMEμ μ ν μ€μ λͺ λ Ήμ΄λ₯Ό κ·Έλλ‘ κ°μ Έμμ΅λλ€.
4. Python
μ¬μpip install pyinstrument
PyPIμ λ°°ν¬λ ν¨ν€μ§λ₯Ό λ°λ‘ μ€μΉν©λλ€. μμ€ ν΄λ‘ μ΄ νμ μμ΅λλ€.
`python -m pyinstrument`. Thanks @asmeurer!
νμ΄μ¬ μ€ν¬λ¦½νΈ(λλ λͺ¨λ)λ₯Ό μ€νν©λλ€.
pip install --upgrade pip
PyPIμ λ°°ν¬λ ν¨ν€μ§λ₯Ό λ°λ‘ μ€μΉν©λλ€. μμ€ ν΄λ‘ μ΄ νμ μμ΅λλ€.
pip install -r requirements-dev.txt
requirements.txt λ±μ λͺ μλ νμ΄μ¬ λΌμ΄λΈλ¬λ¦¬λ₯Ό μ€μΉν©λλ€.
μ΄ λ ν¬μ READMEμ μ ν μ€μ λͺ λ Ήμ΄λ₯Ό κ·Έλλ‘ κ°μ Έμμ΅λλ€.
