You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add a common MDN network interface (consistent with new DensityEstimators) #989
enhancementImprovement planned or wanted by the maintainershackathonFor our in-person hackathons with maintainers present, not a general up-for-grabs list
The MDN (Mixture Density Network) — a Gaussian Mixture Density network — currently receives several "special" treatments in the codebase:
SNPE_A relies on it and implements a custom SNPE_A_MDN wrapper with specific corrections.
SNPE_C uses a specialized loss function for MDN.
conditional_density.py defines a custom ConditionedMDN to handle "marginalization" properties.
Given these various custom implementations, it would be beneficial to consolidate all MDN-related wrappers and functionalities into a single class: MDNDensityEstimator. This new class will adhere to the existing DensityEstimator structure, providing a more unified and streamlined approach.
Advantages:
Reduced Code Duplication: By consolidating the MDN-related code, we eliminate repetitive implementations and centralize the logic.
Improved Typing: A unified class will provide more consistent and clear typing across the library.
Simplified Maintenance: Consolidating MDN functionality into one place will make future updates, bug fixes, and enhancements easier to manage.
This refactor will improve the readability, maintainability, and scalability of the codebase.
I find the SNPE_A_MDN class quite confusing. Is there a loss implemented for it yet? Why does it only inherit from DensityEstimator but not implement all methods?
enhancementImprovement planned or wanted by the maintainershackathonFor our in-person hackathons with maintainers present, not a general up-for-grabs list
Activity
bkmi commentedon Mar 19, 2024
I find the
SNPE_A_MDNclass quite confusing. Is there a loss implemented for it yet? Why does it only inherit fromDensityEstimatorbut not implement all methods?janfb commentedon Jul 22, 2024
This is being worked on in #1042 but it will not make it into the release in August.
janfb commentedon Jan 20, 2026
Needs review in #1724