8000 could not broadcast input array from shape .. · Issue #2333 · Qiskit/qiskit-aer · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

could not broadcast input array from shape .. #2333

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its 8000 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

Open
eginez opened this issue Mar 28, 2025 · 0 comments
Open

could not broadcast input array from shape .. #2333

eginez opened this issue Mar 28, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@eginez
Copy link
eginez commented Mar 28, 2025

Informations

  • Qiskit Aer version:
  • qiskit_aer-0.16.4
  • Python version:
  • 3.11
  • Operating system:
  • linux/debian

What is the current behavior?

When simulating small circuits with fake_sherbrooke we encountered the following error

could not broadcast input array from shape (0,16) into shape (4096,16)
(9 additional frame(s) were not displayed)
...
  File "qiskit/primitives/primitive_job.py", line 51, in result
    return self._future.result()
  File "concurrent/futures/_base.py", line 456, in result
    return self.__get_result()
  File "concurrent/futures/_base.py", line 401, in __get_result
    raise self._exception
  File "concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "qiskit_aer/primitives/sampler_v2.py", line 150, in _run
    pub_results = self._run_pubs([pubs[i] for i in lst], shots)
  File "qiskit_aer/primitives/sampler_v2.py", line 189, in _run_pubs
    self._postprocess_pub(
  File "qiskit_aer/primitives/sampler_v2.py", line 223, in _postprocess_pub
    arrays[item.creg_name][index] = ary

This happens sporadically

Steps to reproduce the problem

Run the estimator with a small circuit like the below on fake_sherbrooke
qc = QuantumCircuit(2)
qc.h(0)
qc.cx(0, 1)
qc.measure_all()

observables = ["ZZ", "XX"]

What is the expected behavior?

Circuit should be simulated without errors

Suggested solutions

@eginez eginez added the bug Something isn't working label Mar 28, 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
0