scope-profiler 0.6.2__tar.gz → 0.6.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (172) hide show
  1. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/CMakeLists.txt +1 -1
  2. {scope_profiler-0.6.2/src/scope_profiler.egg-info → scope_profiler-0.6.4}/PKG-INFO +1 -1
  3. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/pyproject.toml +1 -1
  4. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/__main__.py +3 -3
  5. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mpi_wrappers.py +1 -1
  6. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/profile_manager.py +16 -0
  7. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_main_cli.py +26 -2
  8. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_lazy_config.py +9 -2
  9. {scope_profiler-0.6.2 → scope_profiler-0.6.4/src/scope_profiler.egg-info}/PKG-INFO +1 -1
  10. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/LICENSE.txt +0 -0
  11. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/MANIFEST.in +0 -0
  12. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/README.md +0 -0
  13. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/cmake/scope-profilerConfig.cmake.in +0 -0
  14. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/cmake/CMakeLists.txt +0 -0
  15. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/cmake/main.cpp +0 -0
  16. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/cmake/mpi.cpp +0 -0
  17. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/cmake/native.c +0 -0
  18. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/ex_mpi_numpy_wrappers.py +0 -0
  19. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/ex_mpi_profiling_options.py +0 -0
  20. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/examples/ex_mpi_wrappers.py +0 -0
  21. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/setup.cfg +0 -0
  22. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/__init__.py +0 -0
  23. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/_assets/__init__.py +0 -0
  24. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/_assets/scope-profiler-plotly-0.2.0.js +0 -0
  25. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/benchmark.py +0 -0
  26. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/Makefile +0 -0
  27. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/example.c +0 -0
  28. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler.c +0 -0
  29. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler.h +0 -0
  30. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler.hpp +0 -0
  31. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler_hdf5.h +0 -0
  32. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler_impl.h +0 -0
  33. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/c/scope_profiler_mpi.hpp +0 -0
  34. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/call_stack.py +0 -0
  35. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/chrome_trace_export.py +0 -0
  36. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/concurrency.py +0 -0
  37. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/diff.py +0 -0
  38. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/fortran/Makefile +0 -0
  39. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/fortran/example.f90 +0 -0
  40. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/fortran/scope_profiler.f90 +0 -0
  41. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/gpu_timing.py +0 -0
  42. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/h5reader.py +0 -0
  43. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/h5schema.py +0 -0
  44. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/h5writer.py +0 -0
  45. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/html_report.py +0 -0
  46. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/inspection.py +0 -0
  47. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/ipython_magics.py +0 -0
  48. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/json_export.py +0 -0
  49. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/likwid_data.py +0 -0
  50. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/line_profile_cli.py +0 -0
  51. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mcp_server/__init__.py +0 -0
  52. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mcp_server/__main__.py +0 -0
  53. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mcp_server/server.py +0 -0
  54. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mcp_server/tools.py +0 -0
  55. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/memray.py +0 -0
  56. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/metadata.py +0 -0
  57. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mpi_launch.py +0 -0
  58. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/mpi_region.py +0 -0
  59. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/native_trace.py +0 -0
  60. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/perf_events.py +0 -0
  61. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/__init__.py +0 -0
  62. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/_utils.py +0 -0
  63. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/callgraph.py +0 -0
  64. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/duration_timeseries.py +0 -0
  65. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/durations.py +0 -0
  66. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/flame.py +0 -0
  67. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/gantt.py +0 -0
  68. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/heatmap.py +0 -0
  69. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/histogram.py +0 -0
  70. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/imbalance.py +0 -0
  71. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/likwid.py +0 -0
  72. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/perf_events.py +0 -0
  73. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/roofline.py +0 -0
  74. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/scaling.py +0 -0
  75. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/statistics.py +0 -0
  76. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/plotting_scripts/timeline.py +0 -0
  77. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/post_processing.py +0 -0
  78. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/prof_export.py +0 -0
  79. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/profile_config.py +0 -0
  80. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/profile_io.py +0 -0
  81. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/py.typed +0 -0
  82. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/pytest_plugin.py +0 -0
  83. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/region.py +0 -0
  84. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/region_profiler.py +0 -0
  85. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/results.py +0 -0
  86. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/speedscope_export.py +0 -0
  87. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/summary.py +0 -0
  88. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/__init__.py +0 -0
  89. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/check_mpi_launch.py +0 -0
  90. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/check_parallel_hdf5.py +0 -0
  91. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/examples.py +0 -0
  92. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/examples_pylikwid.py +0 -0
  93. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/README.md +0 -0
  94. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/hdf5-schema-1.h5.gz.b64 +0 -0
  95. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/hdf5-schema-2.h5.gz.b64 +0 -0
  96. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/hdf5-schema-3.h5.gz.b64 +0 -0
  97. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/json-v1.json +0 -0
  98. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/native-v1.spt.b64 +0 -0
  99. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/fixtures/compatibility/native-v2.spt.b64 +0 -0
  100. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/pylikwid_readme.py +0 -0
  101. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_aggregation.py +0 -0
  102. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_api_shortcuts.py +0 -0
  103. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_app.py +0 -0
  104. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_async_profiling.py +0 -0
  105. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_benchmark.py +0 -0
  106. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_buffer_growth.py +0 -0
  107. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_c_api.py +0 -0
  108. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_c_hdf5_output.py +0 -0
  109. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_chrome_trace_export.py +0 -0
  110. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_compatibility_fixtures.py +0 -0
  111. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_diff.py +0 -0
  112. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_documented_formats.py +0 -0
  113. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_fortran_api.py +0 -0
  114. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_html_report.py +0 -0
  115. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_in_memory_results.py +0 -0
  116. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_inspection.py +0 -0
  117. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_ipython_magics.py +0 -0
  118. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_json_export.py +0 -0
  119. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_label.py +0 -0
  120. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_likwid_data.py +0 -0
  121. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_line_profile_cli.py +0 -0
  122. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_mcp_server.py +0 -0
  123. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_mcp_tools.py +0 -0
  124. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_memray.py +0 -0
  125. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_metadata.py +0 -0
  126. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_mixed_language.py +0 -0
  127. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_mpi.py +0 -0
  128. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_multiple_sessions.py +0 -0
  129. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_multiprocessing.py +0 -0
  130. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_output_size.py +0 -0
  131. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_overhead.py +0 -0
  132. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_overhead_io.py +0 -0
  133. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_perf_events.py +0 -0
  134. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_post_processing.py +0 -0
  135. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_prof_export.py +0 -0
  136. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_profile_config_toml.py +0 -0
  137. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_profiling_options.py +0 -0
  138. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_pytest_plugin.py +0 -0
  139. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_readme.py +0 -0
  140. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_region_source.py +0 -0
  141. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_repeated_finalize.py +0 -0
  142. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_results_api.py +0 -0
  143. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_set_version.py +0 -0
  144. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_speedscope_export.py +0 -0
  145. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_storage_size.py +0 -0
  146. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_summary_likwid.py +0 -0
  147. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_threading.py +0 -0
  148. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/test_tui.py +0 -0
  149. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/__init__.py +0 -0
  150. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_call_stack.py +0 -0
  151. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_call_stack_properties.py +0 -0
  152. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_callgraph_plot.py +0 -0
  153. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_concurrency.py +0 -0
  154. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_gpu_timing.py +0 -0
  155. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_h5_failure_paths.py +0 -0
  156. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_h5_roundtrip.py +0 -0
  157. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_h5writer.py +0 -0
  158. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_likwid_child_env.py +0 -0
  159. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_merge_results.py +0 -0
  160. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_mpi_launch.py +0 -0
  161. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_mpi_wrappers.py +0 -0
  162. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_native_hdf5_inputs.py +0 -0
  163. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_native_trace_versions.py +0 -0
  164. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_payload_collection.py +0 -0
  165. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_recursive_tracer.py +0 -0
  166. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tests/unit/test_region_variants.py +0 -0
  167. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler/tui.py +0 -0
  168. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler.egg-info/SOURCES.txt +0 -0
  169. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler.egg-info/dependency_links.txt +0 -0
  170. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler.egg-info/entry_points.txt +0 -0
  171. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler.egg-info/requires.txt +0 -0
  172. {scope_profiler-0.6.2 → scope_profiler-0.6.4}/src/scope_profiler.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  cmake_minimum_required(VERSION 3.15)
2
2
 
3
- project(scope-profiler VERSION 0.6.2 LANGUAGES C CXX)
3
+ project(scope-profiler VERSION 0.6.4 LANGUAGES C CXX)
4
4
 
5
5
  include(GNUInstallDirs)
6
6
  include(CMakePackageConfigHelpers)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: scope-profiler
3
- Version: 0.6.2
3
+ Version: 0.6.4
4
4
  Summary: Profile code regions in python, optionally with LIKWID markers.
5
5
  Author: Max
6
6
  License-Expression: MIT
@@ -5,7 +5,7 @@ requires = [ "setuptools", "wheel" ]
5
5
 
6
6
  [project]
7
7
  name = "scope-profiler"
8
- version = "0.6.2"
8
+ version = "0.6.4"
9
9
  description = "Profile code regions in python, optionally with LIKWID markers."
10
10
  readme = "README.md"
11
11
  keywords = [ "python" ]
@@ -121,14 +121,14 @@ def _parse_run_args(argv):
121
121
  "--mpi-calls",
122
122
  dest="mpi_calls",
123
123
  action="store_true",
124
- default=True,
125
- help="Profile mpi4py calls without changing the target script (default)",
124
+ default=None,
125
+ help="Profile mpi4py calls without changing the target script",
126
126
  )
127
127
  mpi_calls.add_argument(
128
128
  "--no-mpi-calls",
129
129
  dest="mpi_calls",
130
130
  action="store_false",
131
- help="Do not profile mpi4py communication calls",
131
+ help="Do not profile mpi4py communication calls (default)",
132
132
  )
133
133
  parser.add_argument("script", help="Script to run and profile")
134
134
  parser.add_argument(
@@ -421,7 +421,7 @@ def profile_mpi4py(
421
421
  """Temporarily profile mpi4py's predefined communicators.
422
422
 
423
423
  When *lazy* is true, mpi4py is wrapped only if the target imports it. This
424
- lets ``scope-profiler run`` enable MPI-call profiling by default without
424
+ lets ``scope-profiler run --mpi-calls`` enable MPI-call profiling without
425
425
  importing or initializing MPI for an ordinary serial program. Both globals
426
426
  and Python's import function are restored even when the program raises.
427
427
  """
@@ -1459,6 +1459,22 @@ class ProfileManager:
1459
1459
  nothing, so the script above needs no rank guard. See
1460
1460
  :attr:`~scope_profiler.results.ProfilingResults.is_root`.
1461
1461
  """
1462
+ # A lazily resolved default config is not a profiling run. In
1463
+ # particular, decorators call get_config() while they are declared,
1464
+ # so the presence of a config alone cannot be used to decide whether
1465
+ # finalize() should create an output file. setup()/session() replace
1466
+ # the disabled region strategy through set_config().
1467
+ never_activated = cls._region_cls is DisabledProfileRegion and (
1468
+ cls._config is None or not cls._config.deactivate_profiling
1469
+ )
1470
+ if never_activated:
1471
+ if return_results:
1472
+ from scope_profiler.results import ProfilingResults
1473
+
1474
+ file_path = cls._config.file_path if cls._config is not None else ""
1475
+ return ProfilingResults({}, file_path=file_path)
1476
+ return None
1477
+
1462
1478
  config = cls.get_config()
1463
1479
 
1464
1480
  # Read on the same clock as start_time_ns, and as the very first
@@ -107,7 +107,7 @@ def test_run_line_profile_flag_is_passed_to_setup(tmp_path, monkeypatch):
107
107
  assert calls["setup"]["use_line_profiler"] is True
108
108
  assert calls["setup"]["use_memray"] is True
109
109
  assert calls["setup"]["recursive_profile"] is True
110
- assert calls["setup"]["profile_mpi_calls"] is True
110
+ assert calls["setup"]["profile_mpi_calls"] is None
111
111
  assert calls["run_script"] == {
112
112
  "path": str(script),
113
113
  "script_args": ["arg"],
@@ -116,7 +116,7 @@ def test_run_line_profile_flag_is_passed_to_setup(tmp_path, monkeypatch):
116
116
  assert calls["finalize"] == {"verbose": False}
117
117
 
118
118
 
119
- def test_run_enables_mpi_calls_in_profiling_options(tmp_path, monkeypatch):
119
+ def test_run_does_not_enable_mpi_calls_by_default(tmp_path, monkeypatch):
120
120
  script = tmp_path / "script.py"
121
121
  script.write_text("pass\n", encoding="utf-8")
122
122
  calls = {}
@@ -136,6 +136,30 @@ def test_run_enables_mpi_calls_in_profiling_options(tmp_path, monkeypatch):
136
136
 
137
137
  cli_main(["run", str(script)])
138
138
 
139
+ # None lets setup() use its False default, or a config file opt in.
140
+ assert calls["setup"]["profile_mpi_calls"] is None
141
+
142
+
143
+ def test_run_can_enable_automatic_mpi_call_profiling(tmp_path, monkeypatch):
144
+ script = tmp_path / "script.py"
145
+ script.write_text("pass\n", encoding="utf-8")
146
+ calls = {}
147
+
148
+ monkeypatch.setattr(
149
+ "scope_profiler.__main__.ProfileManager.setup",
150
+ lambda **kwargs: calls.update(setup=kwargs),
151
+ )
152
+ monkeypatch.setattr(
153
+ "scope_profiler.__main__.ProfileManager.run_script",
154
+ lambda *args, **kwargs: None,
155
+ )
156
+ monkeypatch.setattr(
157
+ "scope_profiler.__main__.ProfileManager.finalize",
158
+ lambda **kwargs: None,
159
+ )
160
+
161
+ cli_main(["run", "--mpi-calls", str(script)])
162
+
139
163
  assert calls["setup"]["profile_mpi_calls"] is True
140
164
 
141
165
 
@@ -10,6 +10,7 @@ import.
10
10
 
11
11
  import subprocess
12
12
  import sys
13
+ from pathlib import Path
13
14
 
14
15
  from scope_profiler import ProfileManager
15
16
  from scope_profiler.mpi_launch import LAUNCHER_ENV_VARS
@@ -75,10 +76,11 @@ def test_get_config_creates_one_and_keeps_it():
75
76
  assert ProfileManager._config is None
76
77
 
77
78
 
78
- def test_instrumentation_stays_disabled_until_setup_is_called():
79
- """Declaring and running instrumented code does not implicitly opt in."""
79
+ def test_instrumentation_stays_disabled_until_setup_is_called(tmp_path, monkeypatch):
80
+ """Implicit instrumentation records nothing and creates no output file."""
80
81
  from scope_profiler.region_profiler import DisabledProfileRegion
81
82
 
83
+ monkeypatch.chdir(tmp_path)
82
84
  ProfileManager._reset()
83
85
  try:
84
86
 
@@ -95,6 +97,11 @@ def test_instrumentation_stays_disabled_until_setup_is_called():
95
97
  assert isinstance(regions["iteration"], DisabledProfileRegion)
96
98
  assert regions["main"].num_calls == 0
97
99
  assert regions["iteration"].num_calls == 0
100
+
101
+ output_path = Path(ProfileManager.get_config().file_path)
102
+ assert not output_path.exists()
103
+ ProfileManager.finalize(verbose=False)
104
+ assert not output_path.exists()
98
105
  finally:
99
106
  ProfileManager._reset()
100
107
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: scope-profiler
3
- Version: 0.6.2
3
+ Version: 0.6.4
4
4
  Summary: Profile code regions in python, optionally with LIKWID markers.
5
5
  Author: Max
6
6
  License-Expression: MIT
File without changes
File without changes