Skip to content

Refactor network_inspectors.py for modularity and testability #85

Description

@cpaniaguam

Introduce an initial modular package layout for network inspection functionality so future changes don’t accumulate in one large file.

Currently the file mixes network loading, data generation (grids/manifolds), simulator orchestration, and low-level plotting logic. Not surprisingly, the two orchestrator functions kde_vs_lan_likelihoods and lan_manifold have large signatures.

Some initial ideas for the refactor: Data/Config Pattern

  1. Config Objects: Encapsulate model metadata (predictor, name) and plotting defaults (font scale, size) to reduce signature bloat.
  2. Pure Computation: Isolate RT grid generation and likelihood calculations into "headless" functions.
  3. Thin Wrappers: Refactor existing entry points to use these new computation helpers for rendering.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions