scml.std.context ================ .. py:module:: scml.std.context Classes ------- .. autoapisummary:: scml.std.context.BaseStdContext scml.std.context.GeneralStdContext scml.std.context.FixedPartnerNumbersStdContext scml.std.context.LimitedPartnerNumbersStdContext scml.std.context.ANACStdContext scml.std.context.MiddleManStdContext scml.std.context.StrongMiddleManStdContext scml.std.context.BalancedMiddleManStdContext scml.std.context.WeakMiddleManStdContext scml.std.context.SupplierStdContext scml.std.context.StrongSupplierStdContext scml.std.context.BalancedSupplierStdContext scml.std.context.WeakSupplierStdContext scml.std.context.ConsumerStdContext scml.std.context.StrongConsumerStdContext scml.std.context.BalancedConsumerStdContext scml.std.context.WeakConsumerStdContext scml.std.context.StdContext scml.std.context.RepeatingStdContext Module Contents --------------- .. py:class:: BaseStdContext Bases: :py:obj:`scml.oneshot.context.BaseContext` A context that generates std worlds with agents of a given `types` with predetermined structure and settings .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis] .. py:class:: GeneralStdContext Bases: :py:obj:`scml.oneshot.context.GeneralContext` A context that generates std worlds with agents of a given `types` with predetermined structure and settings .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis] .. py:attribute:: perishable :type: bool :value: False .. py:attribute:: horizon :type: int :value: 10 .. py:attribute:: n_processes :type: tuple[int, int] | int :value: (2, 3) .. py:attribute:: disposal_cost :type: tuple[float, float] | float :value: 0 .. py:attribute:: disposal_cost_dev :type: tuple[float, float] | float :value: 0 .. py:attribute:: storage_cost :type: tuple[float, float] | float :value: (0.01, 0.05) .. py:attribute:: storage_cost_dev :type: tuple[float, float] | float :value: 0 .. py:attribute:: price_range_fraction :type: float | tuple[float, float] :value: 0.1 .. py:attribute:: price_multiplier :type: numpy.ndarray | tuple[float, float] | float :value: 0.0 .. py:attribute:: wide_price_range :type: bool :value: False .. py:attribute:: one_time_per_negotiation :type: bool :value: False .. py:attribute:: quantity_multiplier :type: int :value: 3 .. py:attribute:: max_productivity :type: tuple[float, float] | float :value: (0.8, 1.0) .. py:attribute:: max_supply :type: tuple[float, float] | float :value: (0.2, 1.0) .. py:attribute:: exogenous_supply_predictability :type: tuple[float, float] | float :value: (0.0, 0.7) .. py:attribute:: exogenous_sales_predictability :type: tuple[float, float] | float :value: (0.0, 0.7) .. py:attribute:: cap_exogenous_quantities :type: bool :value: False .. py:class:: FixedPartnerNumbersStdContext Bases: :py:obj:`scml.oneshot.context.FixedPartnerNumbersContext` Generates a world limiting the range of the agent level, production capacity and the number of suppliers, consumers, and optionally same-level competitors. .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis] .. py:class:: LimitedPartnerNumbersStdContext Bases: :py:obj:`scml.oneshot.context.LimitedPartnerNumbersOneShotContext` Generates a oneshot world limiting the range of the agent level, production capacity and the number of suppliers, consumers, and optionally same-level competitors. .. py:attribute:: year :type: int :value: 2024 .. py:method:: __attrs_post_init__() .. py:class:: ANACStdContext Bases: :py:obj:`GeneralStdContext` Generates a oneshot world with no constraints except compatibility with a specific ANAC competition year. .. py:attribute:: year :type: int :value: 2024 .. py:method:: __attrs_post_init__() .. py:class:: MiddleManStdContext(*args, **kwargs) Bases: :py:obj:`scml.oneshot.context.LimitedPartnerNumbersOneShotContext` A world context that can generate any world compatible with the observation manager .. py:class:: StrongMiddleManStdContext(*args, **kwargs) Bases: :py:obj:`MiddleManStdContext` A supplier with almost many consumers relative to competitors .. py:class:: BalancedMiddleManStdContext(*args, **kwargs) Bases: :py:obj:`MiddleManStdContext` A supplier with almost same number of consumers as competitors .. py:class:: WeakMiddleManStdContext(*args, **kwargs) Bases: :py:obj:`MiddleManStdContext` A supplier with few consumers relative to competitors .. py:class:: SupplierStdContext(*args, **kwargs) Bases: :py:obj:`scml.oneshot.context.SupplierContext` A world context that can generate any world compatible with the observation manager .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis] .. py:class:: StrongSupplierStdContext(*args, **kwargs) Bases: :py:obj:`SupplierStdContext` A supplier with almost many consumers relative to competitors .. py:class:: BalancedSupplierStdContext(*args, **kwargs) Bases: :py:obj:`SupplierStdContext` A supplier with almost same number of consumers as competitors .. py:class:: WeakSupplierStdContext(*args, **kwargs) Bases: :py:obj:`SupplierStdContext` A supplier with few consumers relative to competitors .. py:class:: ConsumerStdContext(*args, **kwargs) Bases: :py:obj:`scml.oneshot.context.ConsumerContext` A world context that can generate any world compatible with the observation manager .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis] .. py:class:: StrongConsumerStdContext(*args, **kwargs) Bases: :py:obj:`ConsumerStdContext` A consumer with almost many suppliers relative to competitors .. py:class:: BalancedConsumerStdContext(*args, **kwargs) Bases: :py:obj:`ConsumerStdContext` A consumer with almost same number of suppliers as competitors .. py:class:: WeakConsumerStdContext(*args, **kwargs) Bases: :py:obj:`ConsumerStdContext` A consumer with few suppliers relative to competitors .. py:class:: StdContext Bases: :py:obj:`GeneralStdContext` A basic context fixing stationary world config parameters .. py:class:: RepeatingStdContext Bases: :py:obj:`scml.oneshot.context.RepeatingContext` Encapsulates one or more configs and switches between them when asked to generate or make something. .. py:attribute:: world_type :type: type[scml.oneshot.world.SCMLBaseWorld] .. py:attribute:: non_competitors :type: tuple[str | type[scml.oneshot.agent.OneShotAgent], Ellipsis]