# Qiskit No backend matches the criteria

I am trying to run a circuit with 32 qubit on a local hpc (not IBM Q HPC) using statevector_simulator backend.

but i got the following error:

Traceback (most recent call last):
File "testQiskit11.py", line 156, in <module>
backend = Aer.get_backend('statevector_simulator', max_memory_mb=65536)
File "/home/UserName/.conda/envs/quantum/lib/python3.7/site-packages/qiskit/providers/aer/aerprovider.py", line 37, in get_backend
return super().get_backend(name=name, **kwargs)
File "/home/UserName/.conda/envs/quantum/lib/python3.7/site-packages/qiskit/providers/baseprovider.py", line 53, in get_backend
raise QiskitBackendNotFoundError('No backend matches the criteria')
qiskit.providers.exceptions.QiskitBackendNotFoundError: 'No backend matches the criteria'


The part of the script that specify the backend and run the simulation is as follow:

backend = Aer.get_backend('statevector_simulator', max_memory_mb=65536)
backend.MAX_QUBIT_MEMORY=32
shots = 1024
job = execute(QCirc, backend)
result = job.result()


Also, Aer is a local simulator, so the amount of memory available is determined by the computer you are running it on. Setting MAX_QUBIT_MEMORY manually will do nothing but cause your computer to freeze if you do not have enough memory to support 32 qubits.
• My job runs locally on an HPC not related to IBM Q. How to calculate the required amount of memory for simulating 32 qubit. According to this the calculation is as follow: MAX_QUBIT_MEMORY = int( log2(local_hardware_info()['memory'] * (1024**3) / 16))  which get the the number of qubits based on the the memory size and that each element in the state vector requires 16 bytes. And i set max_memory_mb=65536 which is the exact amount of memory required for 32 qubit state vector. – Abdalla Essam Ali Jul 22 '19 at 13:57