agg_check_parfor_chunk: add rev10 orchestration cleanup plus real-input validation and profiling harnesses#18
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c061ce4c93
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| [out95_rev9,outmc_rev9] = agg_check_parfor_chunk_rev9_app(app,agg_check_reliability,point_idx,sim_number,mc_size,radar_beamwidth,base_protection_pts,mc_percentile,on_list_bs,data_label1,reliability,norm_aas_zero_elevation_data,string_prop_model,single_search_dist,off_idx,min_azimuth,max_azimuth,custom_antenna_pattern,cell_aas_dist_data,cell_sim_data,sim_folder,parallel_flag); | ||
| runtime_rev9 = toc; | ||
|
|
||
| % Run rev10 | ||
| tic; |
There was a problem hiding this comment.
Separate rev9 and rev10 artifacts during validation
Running rev9 and rev10 back-to-back with the same arguments causes cross-contamination through shared checkpoint files: both implementations persist to the same *_array_agg_check_95_* and *_array_agg_check_mc_dBm_* names, so the rev10 call can short-circuit and reload rev9 outputs instead of executing its own compute path. In that case deep_compare can report a false PASS and the reported speedup is mostly measuring cache reuse, not rev10 behavior.
Useful? React with 👍 / 👎.
| wall_tic = tic; | ||
| [out95,outmc] = agg_check_parfor_chunk_rev9_app(app,agg_check_reliability,point_idx,sim_number,mc_size,radar_beamwidth,base_protection_pts,mc_percentile,on_list_bs,data_label1,reliability,norm_aas_zero_elevation_data,string_prop_model,single_search_dist,off_idx,min_azimuth,max_azimuth,custom_antenna_pattern,cell_aas_dist_data,cell_sim_data,sim_folder,parallel_flag); %#ok<NASGU> | ||
| wall_runtime_s = toc(wall_tic); |
There was a problem hiding this comment.
Reset agg-check cache before profiling rev9
This profiler invocation does not clear or namespace rev9 checkpoint outputs before timing, but agg_check_parfor_chunk_rev9_app reuses persisted .mat results when they already exist. As a result, repeated profiling runs can measure the fast load path instead of the intended chunk/parfor compute path, which makes the top-contributor table and bucket percentages misleading for optimization decisions.
Useful? React with 👍 / 👎.
Motivation
monte_carlo_Pr_dBm_rev3_appwill be supplied separately.Description
agg_check_parfor_chunk_rev10_app.mwhich was cloned from rev9, keeps the same signature and outputs, documents the Strategy-1 scope, and removes interactivepausestops in the production path while replacing critical NaN checks with fail-closederror(...)guards.parfororchestration, save/load retry loops, and post-assembly cleanup unchanged to retain the existing persistent checkpoint behavior.validate_agg_check_parfor_chunk_rev9_rev10_real.mwhich runs rev9 and rev10 on identical inputs, measures runtimes, computes speedup, performs deep comparisons (numeric/cell/struct with NaN/Inf pattern checks), and fails closed when drift exceeds tolerances.profile_agg_check_parfor_chunk_rev9_real.mwhich profilesagg_check_parfor_chunk_rev9_appon real inputs, reports top contributors, buckets time into orchestration vs downstream compute vs disk activity, and returns a results struct.Testing
rgto confirm presence of expected functions and removal of interactive pauses.Codex Task