GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — meridian/CHANGELOG.md at main · google/meridian

Expand file tree

/

CHANGELOG.md

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
852 lines (727 loc) · 42.3 KB
/

CHANGELOG.md

Copy path

File metadata and controls

852 lines (727 loc) · 42.3 KB
Raw
Copy raw file
Download raw file
Outline
Edit and raw actions

Changelog

Unreleased

2.2.2 - 2026-11-25

  • Add a marginal cost per incremental KPI (mcpik) metric to Analyzer.summary_metrics, computed per draw as the additional spend per additional unit of KPI under the same spend perturbation as mroi. Like mroi, it is only reported when aggregate_times=True and is undefined for the aggregate "All Paid Channels". MediaSummary.summary_table reports it as a monetary column using the median, like cpik.
  • Update mmm-proto-schema dependency to >= 1.8.0.
  • MarketingProcessor now populates Outcome.marginal_cost_per_contribution (e.g. marginal CPA) from the mcpik media summary metric, using the median as the point estimate like cost_per_contribution. As with marginal_roi, it is not set for "All Channels".
  • model.load_mmm() now raises a ValueError directing users to meridian.schema.serde.meridian_serde.load_meridian() when given a protobuf file (.binpb, .txtpb, or .textproto, case-insensitive), or when unpickling the file raises pickle.UnpicklingError, KeyError, or EOFError. Previously it failed with the raw unpickling error, such as KeyError: 10.
  • Fix ValueError: The range [1, X] does not contain any of the available knot lengths: [0] in Automatic Knot Selection (AKS). The knot search may now select no internal knots, in which case AKS returns a single knot representing a common intercept across all time periods, instead of failing.

2.2.1 - 2026-11-18

  • Add include_response_curves to MediaSummarySpec. Set it to False to skip the response curve computation in MarketingProcessor when only the media summary metrics are needed.
  • ModelFit.plot_model_fit() plots can now be panned and zoomed on both the time and the outcome axes: drag to pan, scroll to zoom, and double-click to reset the view. The Model Results Summary report includes the same interaction. To get a plot with fixed axes, pass enable_zoom=False.
  • Fix an XLA compilation crash in JAX sample_posterior when a model has a single-element Deterministic parameter group, such as a single paid media channel or a national model with a single control, reach-and-frequency, or non-media treatment variable.
  • On the JAX backend, sample_posterior now runs the No-U-Turn Sampler (NUTS) on one flat vector of all unconstrained parameters instead of one state part per parameter. It samples from the same posterior with fewer GPU operations per leapfrog step, which reduces GPU sampling time by about 30% on typical models. Posterior draws for a given seed differ from earlier versions. To use the previous sampler, set the MERIDIAN_FLAT_NUTS environment variable to false. The previous sampler and this variable will be removed in the next major version.
  • Fix a ValueError in national models when a hierarchical prior (tau_g_excl_baseline, eta_m, eta_rf, eta_om, eta_orf, xi_c, or xi_n) is a batched Deterministic distribution with one value per channel or geo.
  • Fix get_optimization_bounds rounding channel spend before applying spend constraints. Bounds are now rounded once after scaling, so they no longer exceed WeeklyOptimizationGrid coverage for channels whose spend is close to the rounding step. Optimization bounds and optimized spend can shift by one rounding step compared with earlier versions.
  • Fix PriorDistribution rejecting a valid TruncatedNormal prior that is a component of an IndependentMultivariateDistribution when one of its bounds is in an extreme tail of the untruncated normal distribution. The support of each component is now checked separately.
  • Fix WeeklyOptimizationGrid.to_optimization_grid prematurely rounding historical channel spend before multiplying by the grid's edge spend multipliers when validating optimization bounds, which could falsely reject covered bounds for small channels or accept bounds slightly beyond grid coverage.
  • Indicate zero-contribution periods with unfilled circles (with a matching legend entry) in MediaSummary.plot_channel_contribution_bump_chart and break ranking ties by total incremental outcome across the plotted time periods.
  • Fix IndependentMultivariateDistribution sampling every component with the same seed, which made per-channel prior draws perfectly correlated when the seed was stateless (always on JAX, and on TensorFlow with an integer seed). Each component now gets its own seed. For a fixed seed, the prior draws of an IndependentMultivariateDistribution differ from earlier versions.
  • Rename channel calibration recommendation criterion labels from Driver / Non-Driver to Contributor / Non-Contributor in the Model Health report. meridian.analysis.review.constants.DRIVER and NON_DRIVER are renamed to CONTRIBUTOR and NON_CONTRIBUTOR.
  • Clarify in the Model Health Report's Channel calibration recommendation banner that the overall recommendation is based on the composite calibration score and that flagged criteria are labeled as contributors in the table.

2.2.0 - 2026-11-05

  • Add a balanced option to RandomHoldoutSpec to balance held-out observations across time periods as well as geos.
  • Add ReviewSummary.plot_calibration_overview() and ReviewSummary.plot_calibration_details() to plot the calibration overview (experiments, priors and posterior) and the per-experiment adjustments for all calibrated channels and experiments.
  • Speed up repeated Analyzer calls, such as incremental_outcome for each spend multiplier in Analyzer.response_curves. Dates that are already in YYYY-MM-DD format, such as DataTensors.time, are no longer parsed again each time the data tensors are copied or validated, and the spacing of the same time coordinates is validated only once.
  • Fix a float32/float64 dtype mismatch in adstock_hill.transform_non_negative_reals_distribution on the 64-bit JAX backend by typing the Shift bijector parameter with backend.np_float_dtype.
  • time_coordinates.normalize_date(None) now returns None instead of raising ValueError, with typing overloads so non-None inputs still typecheck as datetime.date.
  • Remove the temporary top-level schema.py compatibility shim module. Use meridian.schema instead.
  • Expose posterior_sampler._compute_tau_g publicly as meridian.model.equations.compute_tau_g, and fix its TypeError for batched inputs on the JAX backend.
  • Add an optional progress_callback argument to Meridian.sample_prior, Meridian.sample_posterior and Meridian.sample_posterior_and_review. The callback receives meridian.model.progress.PriorSamplingProgress and PosteriorSamplingProgress snapshots as sampling advances. On the JAX backend, posterior progress is reported after every MCMC draw, adaptation included; on the TensorFlow backend, once per chain batch.
  • Add meridian.model.progress.TqdmProgressBar, a ready-made progress_callback that displays prior sampling, posterior chain batch and posterior reconstruction progress as tqdm progress bars, with the current stage and the number of divergent transitions. Meridian now depends on tqdm.
  • Enable Jinja2 HTML autoescaping for .html.jinja report templates.
  • Fix NDArrayInputDataBuilder.with_organic_reach setting the organic frequency DataArray name to organic_reach instead of organic_frequency, which caused build() to fail validation with a ValueError.
  • Add an optional media_time_col parameter to DataFrameInputDataBuilder.with_media() and with_reach(), mirroring with_organic_media() and with_organic_reach(). This lets media execution, reach, and frequency use a dedicated media time column that extends before the first time period (for lagged "burn-in" media), while spend uses time_col. Rows with a missing time_col value are excluded from spend. Previously, the only way to model lagged media was to set spend to NaN in the lagged periods.
  • Budget optimization now warns when a channel's response curve is non-monotonic within the optimization bounds, or when the slope_m distribution contains values greater than one, since the optimizer may not find the global optimum in these cases.
  • InputData emits input_data.DataValidationWarning (a UserWarning subclass) when frequency is below 1 where reach is positive, for paid and organic reach and frequency channels, and when any geo has a population of 0 or below. Both usually mean a data error, and a zero or negative population makes the results invalid for every channel. These warnings will become errors in a future major version.
  • Clarify two model-building errors. In a geo model, a variable that is constant everywhere is now reported as not varying across time, instead of as only varying across time when there's one knot per time period. A media, reach, organic media, or organic reach channel that is 0 everywhere now raises an error that names the channel and its type.
  • Fix save_meridian and save_mmm raising FileNotFoundError on bare filenames.
  • Fix calibrated ROI priors so that each candidate distribution minimizes the cross-entropy loss against the numerical posterior, as documented.
  • BayesianPPPCheck now computes the posterior predictive p-value in closed form from the normal predictive distribution of the total outcome for each posterior draw, instead of simulating one replicated total outcome per posterior draw. The p-value no longer varies between runs on the same model. Models with a p-value close to ppp_threshold may get a different check result than in earlier versions.
  • Fix ModelReviewer failing on models that use ROI priors for only some channel types (e.g. ROI priors for media channels and mROI priors for reach and frequency channels). The ROI Consistency, Prior-Posterior Shift, Implausible ROI and High Variance checks now skip channel types whose posterior has no ROI.
  • On the JAX backend, compile the posterior reconstruction step once per sample_posterior call, which lowers its peak device memory and wall time.
  • On the JAX backend, compile the media, RF, organic, and non-media coefficient calculations in sample_prior, which lowers its peak device memory.
  • WeeklyOptimizationGrid resolves the optimal frequency of reach and frequency channels per optimization period, matching create_optimization_grid.
  • Fix spend_share in ReachFrequencyOptimizationProcessor output, which was reported as a percentage instead of a fraction of the total spend.
  • Analyzer.expected_vs_actual_data now always returns an evaluation_set dimension on the expected and baseline data variables. It contains ['All Data'] when the data is not split by holdout_id, and ['Train', 'Test', 'All Data'] when it is. Use .sel(evaluation_set='All Data') to get the previous unsplit shape. ModelFit.model_fit_data is unchanged.
  • Fix contribution_n priors for population-scaled non-media channels with a nonzero baseline value. The baseline was divided by population twice when converting contribution_n to gamma_n, so contribution_n did not match the contribution computed by Analyzer. Refit affected models to get the intended prior.
  • Fix budget optimization stopping early and leaving part of a fixed budget unspent. The search can move a channel's spend several grid points at once. Previously, if the best such move needed more than the remaining budget, the search stopped. It now skips that move and continues with moves that fit.
  • Add allows_negative_aggregate_baseline to ModelSpec to optionally constrain the population-weighted aggregate baseline across time and geos to be non-negative.
  • Update mmm-proto-schema dependency to >= 1.7.0.
  • Allocate spend that is aggregated over the geo and time dimensions once, when the analysis data tensors are built, instead of imputing it separately in Analyzer.get_aggregated_spend. summary_metrics now supports spend provided with dimensions (n_channels,).
  • Fix calibrated ROI priors on the JAX backend so they match TensorFlow.
  • Deprecate the unused optimal_frequency argument of Analyzer.summary_metrics. Passing it now raises a DeprecationWarning and has no effect.
  • Add include_prior and include_posterior arguments to Analyzer.summary_metrics to compute metrics for only the prior or only the posterior distribution. Analyzer.optimal_freq uses them, so optimal_freq and budget optimization with reach and frequency channels no longer require sample_prior() when use_posterior=True.
  • Fix ConcretizationTypeError in sample_posterior on the JAX backend when using IndependentMultivariateDistribution priors (e.g. from CalibrationBuilder) by computing backend.split indices statically.
  • Improve BudgetOptimizer grid generation performance by precomputing batch-invariant Adstock and Hill terms and evaluating reach and frequency channels in a single pass, and scale incremental KPI outcomes directly by kpi_transformer.population_scaled_stdev and population in BudgetOptimizer and Analyzer.inverse_outcome to avoid float32 intercept cancellation. If the Analyzer passed to BudgetOptimizer is a subclass that overrides how incremental outcome is computed, the grid for media channels still calls its incremental_outcome method, so the optimal allocation includes the override.

2.1.0 - 2026-09-17

  • Add get_selected_dates_str to TimeCoordinates.
  • Update mmm-proto-schema dependency to >= 1.4.0.
  • Add a declarative vocabulary to ModelSpec, so that calibration windows, holdouts and population scaling can be expressed with channel names, geo names and dates rather than raw NumPy index arrays. New public types in meridian.model.spec: DateRange, CalibrationSpec, ChannelCalibrationSpec, HoldoutSpec, GeoHoldoutSpec and RandomHoldoutSpec. A DateRange is inclusive of both bounds, and each bound must name one of the input data's time coordinates exactly.
  • Deprecate the five array-valued ModelSpec attributes in favor of declarative equivalents: roi_calibration_period → roi_calibration, rf_roi_calibration_period → rf_roi_calibration, holdout_id → holdout, control_population_scaling_id → population_scaled_controls, and non_media_population_scaling_id → population_scaled_non_media_channels. The deprecated attributes keep working and still take precedence when both members of a pair are set. non_media_baseline_values additionally accepts a channel-name mapping.
  • Add compiled properties to ModelContext that resolve the declarative ModelSpec attributes against the InputData coordinates: compiled_roi_calibration_period, compiled_rf_roi_calibration_period, compiled_holdout_id, compiled_control_population_scaling_id, compiled_non_media_population_scaling_id, compiled_non_media_baseline_values and resolved_random_holdout. The model and analysis layers read these instead of the raw ModelSpec attributes.
  • Persist the declarative ModelSpec attributes through save_meridian and load_meridian. A RandomHoldoutSpec is drawn stratified by geo — each geo holds out the same number of time periods — and the drawn holdout is recorded alongside the spec when the model is saved, so reloading restores the holdout that was actually fitted rather than redrawing it.
  • Add TimeCoordinates.period_ends.
  • Replace direct TensorFlow calls in meridian.model.calibration with meridian.backend to avoid unintended GPU memory pre-allocation when using the JAX backend.
  • Add batch_size to Meridian.sample_prior and PriorDistributionSampler to reduce peak memory usage.
  • Add an include_knots argument to ModelFit.plot_model_fit(), which draws vertical reference lines at the time periods where the model's knots are located.

2.0.0 - 2026-09-02

  • Breaking change: Refactor NotFittedModelError to common.errors.NotFittedModelError.
  • Breaking change: Toggle default backend from TensorFlow to JAX.
  • Add prior calibration through incrementality experiments such as Meridian GeoX.
  • Add channel calibration recommendations.
  • Breaking change: Standardized time selection arguments (selected_times, media_selected_times) across Analyzer and BudgetOptimizer to strictly require date string coordinates (Sequence[str]), removing support for positional boolean masks and normalizing DataTensors.time to tuple[str, ...].
  • Relax jax and jaxlib dependency pins to >= 0.7.2, < 1.0.0 and add jax[cuda12] to [and-cuda] optional dependencies to support Python 3.13 and prevent PJRT accelerator plugin version mismatches.
  • Breaking change: Rename max_rhat to max_r_hat in ConvergenceCheckResult and update R-hat summary metric constants (AVG_R_HAT, MAX_R_HAT, PERCENT_BAD_R_HAT, ROW_IDX_BAD_R_HAT, COL_IDX_BAD_R_HAT) to use the _r_hat convention.
  • Breaking change: Removed Meridian.populate_cached_properties(). Use ModelContext.populate_cached_properties() directly.
  • Breaking change: Change EDASeverity outcome statuses from INFO/ATTENTION/ERROR to INFO/REVIEW/FAIL for consistency across the library.
  • Update BayesianPPPCheck calculation to use the posterior predictive distribution with sigma rather than the posterior expected outcome.
  • Make 64-bit precision the default for the JAX backend. Users can opt out and use 32-bit precision by setting MERIDIAN_ENABLE_JAX_X64=false.
  • Attach the use_kpi attribute to the summary metrics dataset.
  • Add channel-level inspection methods (get_media_scaling_factor, get_channel_parameters, get_channel_parameter_tensor) and ChannelParameters dataclass to ModelContext.
  • Add public methods to Analyzer: incremental_outcome_xr for calculating incremental outcomes as labeled xarray.DataArray objects, get_incremental_kpi, yield_batched_distribution_tensors, and get_kpi_means.
  • Add WeeklyOptimizationGrid to pre-compute weekly incremental outcomes over spend multiplier grids for budget optimization.
  • Add currency_code as an optional ISO 4217 model specification attribute on InputData and InputDataBuilder, with automatic symbol resolution for reporting and optimization visualizations.
  • Fix single-element knots deserialization ambiguity by introducing knots_spec (n_knots and knot_locations) in the Hyperparameters proto and SerDe, deprecating knots with backwards-compatible rehydration support.

1.8.0 - 2026-08-14

  • Implement reconstruction_batch_size to chunk posterior reconstruction evaluations, fixing peak resource exhausted memory crashes on wide modeling pipelines.
  • Update tensorflow, tf-keras, and tensorflow[and-cuda] dependencies to >= 2.21.0, < 2.22 to address CVE-2026-2492.
  • Fix AttributeError: 'Dataset' object has no attribute 'roi_m' when running ModelReviewer on models configured with non-ROI priors (media_prior_type='coefficient' or 'contribution').
  • Fix AKS fallback behavior to correctly generate a single common intercept for non-national models when no internal knots are selected.
  • Add backward-compatible deserialization support in serde (legacy_aks_v1_7_1.py) for models saved with Automatic Knot Selection (enable_aks=True) under v1.7.1.
  • Add validation for prior distribution dtypes to match 64-bit JAX backend precision.
  • Fix spurious UserWarning: Paid media prior type is unspecified during model deserialization by suppressing warnings in ProtoEnumConverter when default_when_unspecified is None.
  • Fix OLS residual variance calculation (use mse_resid rather than mse_resid ** 2) in Automatic Knot Selection.
  • Fix docstring for get_round_factor to accurately describe budget rounding by powers of ten ($10^n$).

1.7.1 - 2026-07-20

  • Enable MeridianEDA._generate_prior_specifications_card and MeridianEDA.plot_prior_mean for national models.
  • Fix ValueError: Interval length between selected times must be consistent when serializing models with calendar-monthly or quarterly time coordinates.
  • Fix a silent attribution misalignment bug in InputData and InputDataBuilder by enforcing strict exact coordinate match ordering across channels.
  • Fix backward-compatibility deserialization error for older legacy models saved with Automatic Knot Selection (enable_aks=True).

1.7.0 - 2026-06-17

  • Fix serialization error in serde when saving models with IndependentMultivariateDistribution priors.
  • Move DataTensors and DistributionTensors out of analyzer.py into tensors.py.
  • Pin matplotlib dependency to < 3.11.0 to fix upstream arviz import error.
  • Fix R&F optimization converters to use optimized channels.
  • Fix a JAX compatibility issue in Summarizer when calling .idxmax() on data backed by JAX.
  • Add support for posterior downsampling for faster, near approximate inference.

1.6.2 - 2026-05-15

  • Filter linear channels from Hill curves and refactor R-hat in visualizer.
  • Fix TypeError by wrapping KPI outcome in backend.to_tensor() in BayesianPPPCheck.
  • Expose inverse_outcome as a public method in Analyzer.

1.6.1 - 2026-04-30

  • Update mmm-proto-schema dependency to >= 1.2.1.

1.6.0 - 2026-04-29

  • Add MeridianEDA for EDA visualizations and two-pager generation.
  • Add support for user-configured EDA Specs.
  • Fix MediaTransformer median calculation when tensor equality is disabled in TensorFlow.
  • Add EDA check for data-to-parameter ratio (DATA_ADEQUACY).
  • JAX support is now available.
  • Add JAX 64-bit precision opt-in configuration.
  • Ensure consistent float precision across tensors, NumPy arrays, and prior distributions.
  • Deprecate model.NotFittedModelError and migrate it to common/errors.py.
  • Deprecate importing model module from analyzer and review modules.

1.5.3 - 2026-03-04

  • Pin arviz dependency to < 0.20.0 to fix upstream InferenceData deprecation.
  • Dropped support for Python 3.10. The minimum required Python version is now 3.11.
  • Upgraded JAX dependencies to version 0.7.2.
  • Refactor model fit plot to include interactive tooltips and hover effects.
  • Fix a bug in tagging in mmm_ui_proto_generator.py.
  • Update MarketingData serialization to support float population values.
  • Add Model Health Summary Card.

1.5.2 - 2026-02-10

  • Move schema package as meridian.schema.
    • Introduce a temporary shim schema.py module for backwards compatibility. This shim will be removed in the next cut release.

1.5.1 - 2026-02-04

  • Fix serialization for binary and text files.

1.5.0 - 2026-01-27

  • Remove dependency on the unmaintained patsy library.
  • Add interactive zooming to prior-posterior distribution plots.
  • Fix plots exceeding the width of the HTML 2-pagers.
  • Raise exception when paid media channels have zero total spend.
  • Include ArviZ version in model serialization.
  • Add more non-negative checks for model input data.
  • Add EDA check for treatment/control geo and time collinearity.
  • Refactored model.Meridian with stateful ModelContext and stateless ModelEquations helper classes.
  • Refactored samplers classes for direct injection of ModelContext and ModelEquations classes.

1.4.0 - 2025-12-08

  • Introduce modules needed for Meridian Scenario Planner and add scenarioplanner extra.

1.3.2 - 2025-11-26

  • Fixed an out-of-bounds bug in EDA's VIF check.
  • Added cost per media unit checks to EDA.
  • Add support for holdout set in GoodnessOfFitCheck.
  • Add more helpful error message for AKS min/max knot selection
  • Add support for python 3.13 and tensorflow 2.20.

1.3.1 - 2025-11-12

  • Fix schema dependency issues.

1.3.0 - 2025-11-10

  • Add EDAEngine for exploratory data analysis.
  • Add model fitting guardrail using EDA to Meridian.
  • Introduce serde package: a serialization and deserialization library for Meridian model with a protocol buffer schema.
  • Add model quality checks in the analysis.review module.
  • Add currency support to optimization summary and visualizer.
  • Expose new hyperparameters in AKS public api.
  • Refactor the TensorFlow RNG handler to use stateless seed generation.
  • Add selected_geos arg to the optimizer.
  • Add selected_geos arg to get_aggregated_spend.
  • Fix bug in optimize() when using new_data with start_date and end_date matching the first and last dates in the new data.
  • Move use_kpi to Summarizer and Visualizer class initialization.
  • Make KPI analysis the default when revenue data is unavailable.

1.2.1 - 2025-09-22

  • Add use_kpi arg to output_model_results_summary.
  • Add lognormal_dist_from_mean_std and lognormal_dist_from_ci helper functions.
  • Add support for forecasted data in the optimization 2-pager visualizations.
  • Change AKS algorithm to use AIC instead of EBIC.
  • Fix dtype issue when scaling integer kpi/population.

1.2.0 - 2025-09-04

  • Fix channel data misalignment in Analyzer.hill_curves when input channels are not in alphabetical order.
  • Add negative_baseline_probability method to Analyzer class.
  • Add per-channel adstock decay function definition.
  • Methods in the analyzer module now return backend-agnostic tensors.
  • Validate distribution support ranges for custom priors.
  • Add IndependentMultivariateDistribution for per-channel distribution definition.
  • Add automatic knot selection (AKS) to modeling.
  • Fix numerical stability of Adstock computation around alpha = 1.
  • Add binomial decay option to Adstock.
  • Make trim_grids() a public method of OptimizationGrid and update it to remove rows of NaNs.
  • Add organic RF support for adstock decay in analyzer.
  • Add organic RF support for Hill curves in analyzer.
  • Set the random_seed in sample_prior() to match the seed parameter.
  • Add organic RF support for plot_hill_curves in visualizer.
  • Raise a ValueError if any media channel have all zeros or all NaN impressions.
  • Add validation for constant KPI with contribution prior types.

1.1.7 - 2025-07-16

  • Fix rhat_summary() to work with a vector sigma dim.

1.1.6 - 2025-07-14

  • Convert stateful seeds into stateless seeds in sample_posterior() to ensure the sampling is deterministic.

1.1.5 - 2025-07-10

  • Remove sigma_dims pseudo-dimension from inference data.
  • Sets builder-wide default column names in DataFrameInputDataBuilder.

1.1.4 - 2025-06-30

  • XrDatasetDataLoader to use new InputDataBuilder API under the hood. These changes are backwards compatible.
  • Fix mishandling of an empty controls column list in the data loader params.
  • Maintain user-given channel ordering in InputData's channels' coordinates.

1.1.3 - 2025-06-23

  • Add MLflow autologging support.
  • Fix bug where channels were being mapped to the wrong column name.
  • Add the ability to set max_frequency to optimal_freq() and update the new_data argument to take in rf_impressions rather than reach and frequency separately.
  • Add a helper method to create new data for optimizations with just spend or impressions and CPM. This includes geo allocation based on population.

1.1.2 - 2025-06-11

  • Add new InputDataBuilder APIs.
  • DataFrameDataLoader to use new DataFrameInputDataBuilder API under the hood. These changes are backwards compatible.
  • Keep rounded spend as int64 in optimizer.

1.1.1 - 2025-05-28

  • Rename the directory of unit testing datasets from sample to unit_testing_data and add a README.
  • Make controls data optional in the model.
  • Add a time variation error message for national models.

1.1.0 - 2025-05-20

  • Add media_prior_type, rf_prior_type, organic_media_prior_type, organic_rf_prior_type, non_media_prior_type parameters to ModelSpec.
  • Add 'contribution' prior type option.
  • Add a data simulation demo notebook and update/add simulated datasets.
  • Change VEGALITE_FACET_EXTRA_LARGE_WIDTH from 900 to 700.
  • Prevent negative media effect priors when using lognormal distribution upon model init.
  • Add an optional optimization_grid arg to the optimizer.
  • Fix incremental_outcome to accept unscaled non_media_treatments_baseline.
  • Add spend allocation per geo and time if per-channel spend is provided.
  • Validate no time variation for non-media treatments, organic media, and organic reach.
  • Add optimizer parameters start_date and end_date to replace selected_times.

1.0.9 - 2025-04-17

  • Add support for optimization with forecasted data.
  • Deprecate get_historical_spend for get_aggregated_spend with new_data support.
  • Raise an error when kpi_scaled is all zero and paid_media_prior_type is anything other than "coefficient".
  • Prevent negative media effect priors when using lognormal distribution.
  • Add support for weekly time granularity to the contribution area and bump charts.
  • Update channel contribution over time charts in Summarizer to toggle weekly vs quarterly granularity based on the selected time period length.
  • Adjust the optimization summary to display dates in the same format as "Marketing Mix Modeling Report".
  • Increase width of model fit and channel contribution over time charts in the Visualizer.

1.0.8 - 2025-04-08

  • Update contribution calculation methods in MediaSummary with aggregate_times parameter to support granular time.
  • Add a new_data argument to analyzer.optimal_freq().
  • Refactor args in create_optimization_grid to be consistent with optimize(...).
  • Fix response curves for KPI-based optimization.
  • Add plot_channel_contribution_area_chart method to MediaSummary in the visualizer.
  • Add plot_channel_contribution_bump_chart method to MediaSummary in the visualizer.
  • Add organic media support for adstock decay in analyzer.
  • Add channel contribution area chart and channel contribution bump chart to model results summary report in the summarizer.
  • Add an extra check for zeros or negative values in revenue_per_kpi.
  • Add per-channel constraints parameters to OptimizationGrid.optimize(...).
  • Add organic media support for hill curves in analyzer.
  • Add organic media support for plot_hill_curves in visualizer.

1.0.7 - 2025-03-19

  • Bump tensorflow to 2.18.
  • Bump tensorflow-probability to 0.25.
  • Bump numpy to 2.0.2.
  • Bump pandas to 2.2.2.
  • Bump scipy to 1.13.1.

1.0.6 - 2025-03-18

  • Fix issue #548: Make time coordinate regularity check less stringent.
  • Force DataTensors to have all tensors with dtype=tf.float32.
  • Refactor new data validation and data filling into the DataTensors class.
  • Fix bug in marginal ROI calculation in summary_metrics when new spend data is passed in.
  • Add by_reach param to incremental_outcome() to allow scaling reach or frequency.
  • Refactor marginal_roi() and the mROI calculation in summary_metrics to use the scaling factors in incremental_outcome(), removing duplicate code.
  • Allow new_data to have any number of time dimensions for roi(), marginal_roi(), cpik(), and summary_metrics(). This allows the use of forecasted data for analysis.
  • Add optimize() method to the OptimizationGrid dataclass.
  • Add a warning when the target constraint of flexible budget optimization is not met.

1.0.5 - 2025-03-06

  • Add technical support for python 3.10.
  • Align NaNs in spend_grid and incremental_outcome_grid in the optimizer.
  • Fix the stopping criteria of target total ROI in flexible budget optimization.
  • Separate creation of the grid data and the optimization.

1.0.4 - 2025-02-28

  • Fix validation on injected inference data when unique_sigma_for_each_geo is used in the model initialization.
  • Fix a divide-by-zero error in spend ratio calculation when historical spend is zero, preventing a ValueError in output_optimization_summary.
  • Add non_media_baseline_values argument to MediaSummary visualizations.
  • Refactor prior and posterior sampling logic into separate modules, simplifying model module.
  • Create a helper argument builder construct for API parameters that require an ordered list/array of values. See, e.g., InputData.get_paid_channels_argument_builder().

1.0.3 - 2025-02-07

  • Temporarily downgrade tensorflow version to 2.16 until the convergence issues on L4 and A100 GPU runtimes are resolved.

1.0.2 - 2025-02-06

  • Bump minimum tensorflow version to 2.18.
  • Add [and-cuda] optional dependencies to install tensorflow dependency with GPU support.
  • Add non_media_baseline_values argument to summary_metrics, baseline_summary_metrics and expected_vs_actual methods.
  • Update compute_incremental_outcome_aggregate docstring to match incremental_outcome.

1.0.1 - 2025-02-04

  • Bump minimum pandas version to 2.2.
  • Make compute_incremental_outcome_aggregate public.
  • Add new_data argument to Analyzer.summary_metrics method.
  • Add use_kpi argument to the optimize() method.

1.0.0 - 2025-01-24

  • Bump tensorflow version to 2.16 to support Python 3.12.

0.17.0 - 2025-01-23

  • Define constants for channel constraints in the optimizer.
  • Remove aggregate_times from roi, marginal_roi, and cpik methods in Analyzer and do not report these metrics in the summary_metrics method when aggregate_times=False as these metrics do not have a clear interpretation by time period.

0.16.0 - 2025-01-08

  • Organize tensor arguments of roi, mroi, and cpik methods of Analyzer into a DataTensors container.
  • Add warning message when user sets custom priors that will be ignored by the paid_media_prior_type argument.

0.15.0 - 2025-01-07

  • Convert InputData geo coordinates to strings upon initialization to avoid type mismatches with GeoInfo proto which expects strings.
  • Add get_historical_spend method to Analyzer class.
  • Split up roi_* and mroi_* parameters.

0.14.0 - 2024-12-17

  • Remove deprecated use_roi_prior attribute from ModelSpec.

0.13.0 - 2024-12-11

  • Add support for marginal ROI priors in Meridian.

0.12.0 - 2024-12-09

  • Rename incremental_impact to incremental_outcome.
  • Rename plot_incremental_impact_delta to plot_incremental_outcome_delta.

0.11.2 - 2024-11-27

  • Remove deprecated all_channel_names property from Meridian class.

0.11.1 - 2024-11-22

  • Remove unneeded argument include_non_paid_channels from expected_outcome().
  • Fix a bug in the custom RF prior validation.

0.11.0 - 2024-11-19

  • Consistent naming for "rhat" methods.

0.10.0 - 2024-11-18

  • Add support for organic media, organic reach and frequency, and non-media treatment variables.
  • Rename Analyzer.media_summary_metrics method to Analyzer.summary_metrics with include_non_paid_channels argument.

0.9.0 - 2024-11-15

  • Organize arguments of incremental_impact and expected_outcome methods into a DataTensors container.

0.8.0 - 2024-11-05

  • Expand media summary metrics to return ROI, mROI, and CPIK in all scenarios with the addition of the use_kpi argument.
  • Optimal frequency now calculates the frequency that maximizes the mean ROI in all cases such that it is consistent when used in the budget optimization that optimizes revenue.
  • Fix an error in the data loader that occurs when the geo column is an integer.
  • Add a _check_if_no_time_variation method to Meridian to raise an error if a variable has no time variation.
  • Make the performance breakdown section of the model summary report display both ROI and CPIK charts for all scenarios.
  • Set default ROI priors for non-revenue, no revenue-per-KPI models.
  • Do not specify significant digits in the y-axis labels in plot_spend_delta, trim insignificant trailing zeros in all charts.
  • Rename ControlsTransformer to CenteringAndScalingTransformer.

0.7.0 - 2024-09-20

  • Make get_r_hat public.
  • Add media_selected_times parameter to Analyzer.incremental_impact() method. This allows, among other things, to project impact for future media values.
  • For "All Channels" media summary metrics: effectiveness and mroi data variables are now masked out (math.nan).
  • Introduce a data.TimeCoordinates construct.
  • Pin numpy dependency to ">= 1.26, < 2".
  • InputData now has [media_]*time_coordinates properties.
  • InputData now explicitly checks that time coordinate values are evenly spaced.

0.6.0 - 2024-08-20

  • Add Analyzer.baseline_summary_metrics() method.
  • Fix a bug where custom priors were sometimes not able to be detected.
  • Fix a bug in the controls transformer with mean and stddev computations.

0.5.0 - 2024-08-15

  • Include pct_of_contribution and effectiveness data to OptimizationResults datasets.
  • Add Analyzer.get_aggregated_impressions() method.
  • Add spend_step_size to OptimizationResults.optimization_grid.
  • Add use_posterior argument to the budget optimizer.
  • Rename expected_impact to expected_outcome.

0.4.0 - 2024-07-19

  • Refactor BudgetOptimizer.optimize() API: it now returns an OptimizationResults dataclass.

0.3.0 - 2024-07-19

  • Rename tau_t to mu_t throughout.

0.2.0 - 2024-07-16

0.1.0 - 2022-01-01

  • Initial release
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.