Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User-defined media transformations and custom ordering #632

Merged
Merged
Show file tree
Hide file tree
Changes from 107 commits
Commits
Show all changes
120 commits
Select commit Hold shift + click to select a range
0275e70
Allowing Custom Saturation & Lagging functions
cetagostini-wise Apr 15, 2024
fbdb940
Small adding
cetagostini-wise Apr 15, 2024
ad9eb6a
test commit to carlos branch
wd60622 Apr 16, 2024
b1319aa
hook up saturation class to lift method
wd60622 Apr 16, 2024
7ef1b95
pull out last saturation function into method
wd60622 Apr 16, 2024
64db1c2
migrate the logic for tests
wd60622 Apr 16, 2024
eff63fe
reduce what is needed for a new class
wd60622 Apr 16, 2024
981d958
remove the noqa
wd60622 Apr 16, 2024
79408b8
model docstring for inheritance
wd60622 Apr 16, 2024
0374d3b
rewrite of the components
wd60622 Apr 23, 2024
4022069
rewrite of the components
wd60622 Apr 23, 2024
e143e12
change name to logistic
wd60622 Apr 23, 2024
5beccc4
map names for model_config
wd60622 Apr 23, 2024
dfa288c
Merge pull request #1 from pymc-labs/saturation-components-for-lift-t…
cetagostini-wise Apr 23, 2024
e82e9f2
Merge branch 'main' into dev-allowing-custom-functions
wd60622 Apr 23, 2024
5705550
switch out order
wd60622 Apr 24, 2024
0784d25
Merge pull request #2 from pymc-labs/forward-pass-order
cetagostini-wise Apr 24, 2024
6141423
Changes
cetagostini-wise Apr 24, 2024
69e30ae
solving issues
cetagostini-wise Apr 25, 2024
59fe50b
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Apr 25, 2024
daa611d
solving errors
cetagostini-wise Apr 25, 2024
954d6f1
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini-wise Apr 25, 2024
b3e42db
New class name
cetagostini-wise Apr 25, 2024
e94359f
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] Apr 25, 2024
5a8e06b
Update pymc_marketing/mmm/transformers.py
cetagostini Apr 25, 2024
a6a127b
pre-commit change
cetagostini-wise Apr 27, 2024
6f9c566
Update pymc_marketing/mmm/models/components/base.py
cetagostini Apr 27, 2024
d2cd773
Update pymc_marketing/mmm/models/components/saturation.py
cetagostini Apr 27, 2024
5426fe1
Update pymc_marketing/mmm/models/components/lagging.py
cetagostini Apr 27, 2024
389aed0
Requested changes
cetagostini-wise Apr 27, 2024
0fbacdc
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini-wise Apr 27, 2024
3a071f5
pre-commit changes
cetagostini-wise Apr 27, 2024
f98e15f
Requested changes
cetagostini-wise Apr 27, 2024
8b51e25
more changes
cetagostini-wise Apr 27, 2024
725854f
Merge branch 'main' into dev-allowing-custom-functions
wd60622 Apr 30, 2024
e427d6a
Merge branch 'main' into dev-allowing-custom-functions
wd60622 May 2, 2024
22c38fe
Merge branch 'main' into dev-allowing-custom-functions
wd60622 May 5, 2024
8e0ef35
use reserved parameter name
wd60622 May 5, 2024
614d068
Returning name and adding deprecation warning
cetagostini-wise May 5, 2024
501c511
Re-structuring the budget optimizer
cetagostini-wise May 5, 2024
91b9418
Update pymc_marketing/mmm/components/adstock.py
cetagostini-wise May 5, 2024
e139ca6
Will recommendations
cetagostini-wise May 5, 2024
da770dc
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini-wise May 5, 2024
36b9205
Temporal comment
cetagostini-wise May 5, 2024
954892c
test more assumed behavior
wd60622 May 6, 2024
a1c0441
Merge pull request #3 from pymc-labs/new-transform-tests
cetagostini-wise May 6, 2024
96b95e9
Merge branch 'main' into dev-allowing-custom-functions
wd60622 May 6, 2024
364aed5
more budget optimizer changes
cetagostini-wise May 6, 2024
bd95893
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini-wise May 6, 2024
433a075
docstrings for classes
wd60622 May 6, 2024
3d4d50b
small changes about l_max on adstock
cetagostini-wise May 6, 2024
0b1a5f4
small addition
cetagostini-wise May 9, 2024
23309fd
Update pymc_marketing/mmm/delayed_saturated_mmm.py
cetagostini-wise May 9, 2024
2d5bb44
temporal notebook copy
cetagostini-wise May 9, 2024
fa86565
update
cetagostini-wise May 9, 2024
c83bd33
Merge branch 'main' into dev-allowing-custom-functions
cetagostini-wise May 9, 2024
4ba0c07
docstring
cetagostini-wise May 9, 2024
f749b09
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini-wise May 9, 2024
d57d9ad
adding missing
cetagostini-wise May 9, 2024
7432e09
Merge pull request #4 from pymc-labs/transformation-docstrings
cetagostini-wise May 13, 2024
4007adc
Update pymc_marketing/mmm/components/adstock.py
cetagostini May 21, 2024
c64533e
Update pymc_marketing/mmm/components/adstock.py
cetagostini May 21, 2024
052dfae
Merge branch 'main' into dev-allowing-custom-functions
cetagostini May 21, 2024
f58ff37
Making mypy happy part 1
cetagostini May 24, 2024
3048f7d
Merge branch 'main' into dev-allowing-custom-functions
cetagostini-wise May 24, 2024
70b5dba
Small example
cetagostini May 24, 2024
0fe4183
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini May 24, 2024
eed50eb
finally?
cetagostini May 25, 2024
73ec885
small change
cetagostini May 25, 2024
b66f169
docstrings
cetagostini May 25, 2024
2485d70
removing mokeytype
cetagostini May 25, 2024
bf55679
more docstrings
cetagostini May 25, 2024
82b988c
Update pymc_marketing/mmm/transformers.py
cetagostini-wise May 27, 2024
ea06134
tests for out of box saturation and adstocks
wd60622 May 31, 2024
66cd68e
test the passthrough
wd60622 May 31, 2024
554118c
Merge branch 'main' into dev-allowing-custom-functions
wd60622 May 31, 2024
cdc8144
Merge branch 'main' into dev-allowing-custom-functions
wd60622 Jun 3, 2024
68607b8
Merge pull request #5 from pymc-labs/adstock-saturation-tests
cetagostini-wise Jun 3, 2024
582acd0
Merge branch 'main' into dev-allowing-custom-functions
cetagostini Jun 3, 2024
da81410
Update pymc_marketing/mmm/components/adstock.py
cetagostini Jun 3, 2024
1524588
Changes on hints
cetagostini Jun 3, 2024
aea05c3
modifications
cetagostini Jun 3, 2024
4cc4933
Merge branch 'main' into dev-allowing-custom-functions
cetagostini Jun 3, 2024
1f906f9
notebooks addition
cetagostini Jun 3, 2024
03794c4
Update notebook
cetagostini Jun 3, 2024
b87a4b1
Saving model
cetagostini Jun 3, 2024
3757934
mock the fit and move tests around
wd60622 Jun 4, 2024
cb25476
fix get_distribution tests
wd60622 Jun 4, 2024
c4364c1
Merge pull request #6 from pymc-labs/fix-mmm-plotting-tests
cetagostini-wise Jun 4, 2024
3e8177b
Correct error
cetagostini Jun 4, 2024
d3c1b38
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini Jun 4, 2024
5bacf2b
Deprecation warning and new MMM class
cetagostini Jun 4, 2024
66b4389
Small changes
cetagostini Jun 4, 2024
6964d8a
updates
cetagostini Jun 4, 2024
4b33be1
add a lookup for model saving
wd60622 Jun 5, 2024
7a170f7
Merge pull request #7 from pymc-labs/use-mmm-class-wrapper
wd60622 Jun 5, 2024
1d9d91f
fix tests based on recent changes
wd60622 Jun 5, 2024
b971b30
Merge pull request #8 from pymc-labs/fix-delayed-mmm-tests
wd60622 Jun 5, 2024
db254a3
Deleting decimals
cetagostini Jun 6, 2024
62db857
test suite
cetagostini Jun 6, 2024
c5c565c
Update tests/mmm/test_budget_optimizer.py
wd60622 Jun 6, 2024
aef1dac
Update tests/mmm/test_budget_optimizer.py
wd60622 Jun 6, 2024
971559a
running notebooks
cetagostini Jun 6, 2024
3081e5d
adding hint
cetagostini Jun 6, 2024
c011f10
initial docstring check
cetagostini Jun 6, 2024
3076ae3
update docstrings 1
cetagostini Jun 7, 2024
98d581d
Modifying notebook
cetagostini Jun 7, 2024
8f54a30
use explicit adstock and saturation in MMM
wd60622 Jun 8, 2024
e196fcd
remove reference to DelayedSaturatedMMM
wd60622 Jun 8, 2024
4c60528
request changes
cetagostini Jun 8, 2024
92136b5
Merge branch 'dev-allowing-custom-functions' of https://github.com/ce…
cetagostini Jun 8, 2024
2d9f5e4
missing total
cetagostini Jun 8, 2024
9120b3d
modify docstring
cetagostini Jun 8, 2024
07bcb0e
modify eval
cetagostini Jun 8, 2024
943b0b3
Small changes
cetagostini Jun 8, 2024
7b11203
change
cetagostini Jun 8, 2024
4df4708
changes
cetagostini Jun 8, 2024
11ddcc7
import saturation in docstring
wd60622 Jun 10, 2024
889ae2c
Merge branch 'main' into dev-allowing-custom-functions
wd60622 Jun 10, 2024
114dbc2
pre-commit
cetagostini Jun 10, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file renamed data/budget_optimizer_model.nc → data/model.nc
Binary file not shown.
2,474 changes: 1,128 additions & 1,346 deletions docs/source/notebooks/mmm/mmm_budget_allocation_example.ipynb

Large diffs are not rendered by default.

3,525 changes: 2,013 additions & 1,512 deletions docs/source/notebooks/mmm/mmm_example.ipynb

Large diffs are not rendered by default.

789 changes: 403 additions & 386 deletions docs/source/notebooks/mmm/mmm_lift_test.ipynb

Large diffs are not rendered by default.

175 changes: 87 additions & 88 deletions docs/source/notebooks/mmm/mmm_tvp_example.ipynb

Large diffs are not rendered by default.

34 changes: 31 additions & 3 deletions pymc_marketing/mmm/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,25 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from pymc_marketing.mmm import base, delayed_saturated_mmm, preprocessing, validating
from pymc_marketing.mmm.base import MMM, BaseMMM
from pymc_marketing.mmm.delayed_saturated_mmm import DelayedSaturatedMMM
from pymc_marketing.mmm.base import (
BaseValidateMMM,
MMMModelBuilder,
)
from pymc_marketing.mmm.components.adstock import (
AdstockTransformation,
DelayedAdstock,
GeometricAdstock,
WeibullAdstock,
)
from pymc_marketing.mmm.components.saturation import (
HillSaturation,
LogisticSaturation,
MichaelisMentenSaturation,
SaturationTransformation,
TanhSaturation,
TanhSaturationBaselined,
)
from pymc_marketing.mmm.delayed_saturated_mmm import MMM, DelayedSaturatedMMM
from pymc_marketing.mmm.preprocessing import (
preprocessing_method_X,
preprocessing_method_y,
Expand All @@ -26,10 +43,21 @@
"preprocessing",
"validating",
"MMM",
"BaseMMM",
"MMMModelBuilder",
"BaseValidateMMM",
"DelayedSaturatedMMM",
"preprocessing_method_X",
"preprocessing_method_y",
"validation_method_X",
"validation_method_y",
"AdstockTransformation",
"DelayedAdstock",
"GeometricAdstock",
"WeibullAdstock",
"SaturationTransformation",
"MichaelisMentenSaturation",
"HillSaturation",
"LogisticSaturation",
"TanhSaturation",
"TanhSaturationBaselined",
]
Loading
Loading