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

layer_noise_model should accept None #2103

Open
jyu00 opened this issue Jan 15, 2025 · 0 comments
Open

layer_noise_model should accept None #2103

jyu00 opened this issue Jan 15, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@jyu00
Copy link
Collaborator

jyu00 commented Jan 15, 2025

Describe the bug

The description for layer_noise_model currently says

    layer_noise_model: Union[UnsetType, NoiseLearnerResult, Sequence[LayerError]] = Unset
    r"""A :class:`NoiseLearnerResult` or a sequence of :class:`LayerError`
        objects. If set, all the mitigation strategies that require noise data (e.g., PEC and
        PEA) skip the noise-learning stage, and instead gather the required information from
        ``layer_noise_model``. Layers whose information is missing in ``layer_noise_model``
        are treated as noiseless and their noise is not mitigated.
    """

The Unset value is used to indicate server default will be used, and that default is subject to change.

This option should accept None as a valid value for a user to explicitly indicate they don't want to use an existing model, nor do they want to use the server default (even if that default is not to use any existing model). Not accepting None also means if I set it by mistake, there is no way to unset it (Unset is not public).

The docstring should also say what the server default is (e.g. None).

cc @SamFerracin

Steps to reproduce

Expected behavior

Suggested solutions

Additional Information

  • qiskit-ibm-runtime version:
  • Python version:
  • Operating system:
@jyu00 jyu00 added the bug Something isn't working label Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant