Join the newly launched Discord
community for real-time discussions, peer support, and direct interaction with the Meridian team!
meridian.model.media.OrganicMediaTensors
Stay organized with collections
Save and categorize content based on your preferences.
Container for organic media tensors.
meridian
.
model
.
media
.
OrganicMediaTensors
(
organic_media
:
(
meridian
.
backend
.
Tensor
|
None
)
=
None
,
organic_media_transformer
:
(
meridian
.
model
.
transformers
.
MediaTransformer
|
None
)
=
None
,
organic_media_scaled
:
(
meridian
.
backend
.
Tensor
|
None
)
=
None
)
organic_media_transformer
A MediaTransformer
to scale media tensors using
the model's organic media data.
The organic media tensor normalized by population and
by the median value.
Methods
__eq__
__eq__
(
other
)
Return self==value.
organic_media_transformer
None
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-09-05 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-05 UTC."],[[["\u003cp\u003e\u003ccode\u003eOrganicMediaTensors\u003c/code\u003e is a container class for various organic media tensors used in the meridian model.\u003c/p\u003e\n"],["\u003cp\u003eThe class holds tensors such as \u003ccode\u003eorganic_media\u003c/code\u003e, \u003ccode\u003eorganic_media_scaled\u003c/code\u003e, \u003ccode\u003eorganic_media_counterfactual\u003c/code\u003e, and \u003ccode\u003eorganic_media_counterfactual_scaled\u003c/code\u003e, as well as a \u003ccode\u003eMediaTransformer\u003c/code\u003e for scaling.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eorganic_media\u003c/code\u003e represents a tensor constructed from \u003ccode\u003eInputData.organic_media\u003c/code\u003e, while \u003ccode\u003eorganic_media_scaled\u003c/code\u003e is normalized by population and the median value.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eorganic_media_counterfactual\u003c/code\u003e and \u003ccode\u003eorganic_media_counterfactual_scaled\u003c/code\u003e store counterfactual values, and scaled counterfactual values respectively.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eOrganicMediaTensors\u003c/code\u003e includes an \u003ccode\u003e__eq__\u003c/code\u003e method for comparison and several class variables initialized to \u003ccode\u003eNone\u003c/code\u003e that correspond to the attributes of the class.\u003c/p\u003e\n"]]],["`OrganicMediaTensors` is a container for media tensors, including `organic_media` derived from `InputData`, and a `MediaTransformer` for scaling. It stores the original media, scaled media (`organic_media_scaled`), counterfactual media (`organic_media_counterfactual`), and scaled counterfactual media (`organic_media_counterfactual_scaled`). The class provides methods such as `__eq__` for comparison. Additionally, class variables, initially set to `None`, represent these different media states and the transformer.\n"],null,["\u003cbr /\u003e\n\n|-----------------------------------------------------------------------------------------------------------|\n| [View source on GitHub](https://github.com/google/meridian/blob/v1.2.0/meridian/model/media.py#L164-L178) |\n\nContainer for organic media tensors. \n\n meridian.model.media.OrganicMediaTensors(\n organic_media: (../../../meridian/backend/Tensor.md | None) = None,\n organic_media_transformer: (../../../meridian/model/transformers/MediaTransformer.md | None) = None,\n organic_media_scaled: (../../../meridian/backend/Tensor.md | None) = None\n )\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Attributes ||\n|-----------------------------|----------------------------------------------------------------------------------------------------------------------|\n| `organic_media` | A tensor constructed from [`InputData.organic_media`](../../../meridian/data/input_data/InputData.md#organic_media). |\n| `organic_media_transformer` | A `MediaTransformer` to scale media tensors using the model's organic media data. |\n| `organic_media_scaled` | The organic media tensor normalized by population and by the median value. |\n\n\u003cbr /\u003e\n\nMethods\n\n`__eq__` \n\n __eq__(\n other\n )\n\nReturn self==value.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Class Variables ||\n|---------------------------|--------|\n| organic_media | `None` |\n| organic_media_scaled | `None` |\n| organic_media_transformer | `None` |\n\n\u003cbr /\u003e"]]