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
As an engineer, it would be nice if there were clear abstractions in multi table modeling that could be used to add new multi table synthesizers.
The image above lays out the generalized common modeling steps all multi table synthesizers should use. Currently, the HMASynthesizer breaks this abstraction as it models each table in the middle box while doing its extending. This can be seen on the following lines of HMASynthesizer._model_table.
To match the desired abstraction we should take the following steps:
Add an abstract method to the BaseMultiTableSynthesizer class called _augment_tables. This method should be implemented in any child class and be responsible for augmenting tables with the necessary information to model them.
Add another abstract method called _model_tables to the base. This method should just be used to loop through and model tables.
Refactor the HSASynthesizer to break up modeling into these two methods.
BaseMultiTableSynthesizer.fit will now call preprocess -> _augment_tables -> _model_tables
Additional context
In HMA, we only need to model the root table. Currently we model every table. This change can be made in the new _model_tables implementation.
The text was updated successfully, but these errors were encountered:
Problem Description
As an engineer, it would be nice if there were clear abstractions in multi table modeling that could be used to add new multi table synthesizers.
The image above lays out the generalized common modeling steps all multi table synthesizers should use. Currently, the
HMASynthesizer
breaks this abstraction as it models each table in the middle box while doing its extending. This can be seen on the following lines ofHMASynthesizer._model_table
.SDV/sdv/multi_table/hma.py
Lines 198 to 199 in 904aa2d
Expected behavior
To match the desired abstraction we should take the following steps:
_augment_tables
. This method should be implemented in any child class and be responsible for augmenting tables with the necessary information to model them._model_tables
to the base. This method should just be used to loop through and model tables.HSASynthesizer
to break up modeling into these two methods.BaseMultiTableSynthesizer.fit
will now callpreprocess
->_augment_tables
->_model_tables
Additional context
_model_tables
implementation.The text was updated successfully, but these errors were encountered: