Problem when running QPU Pennylane-rigetti

Hello Pennylane Team,
I have problem with this documentation
https://docs.pennylane.ai/projects/rigetti/en/stable/devices/qpu.html

can you help me to solve this problem?
Code:

import pennylane as qml
dev_qpu = qml.device('rigetti.qpu', device='Aspen-M-2', shots=1000)

Error:

---------------------------------------------------------------------------
QCSHTTPStatusError                        Traceback (most recent call last)
<ipython-input-2-b74f3ee6e145> in <cell line: 0>()
----> 1 dev_qpu = qml.device('rigetti.qpu', device='Aspen-M-2', shots=1000)

8 frames
/usr/local/lib/python3.11/dist-packages/qcs_api_client/util/errors.py in raise_for_status(res)
     31         pass
     32 
---> 33     raise QCSHTTPStatusError(message, error=error, response=res)

QCSHTTPStatusError: QCS API call GET https://api.qcs.rigetti.com/v1/quantumProcessors/Aspen-M-2/instructionSetArchitecture failed with status 401: {"code":"unauthenticated","message":"authorization error","requestCorrelationId":"68630c80-f8b6-4102-86f7-e147dcfd184a","requestId":"dc33b577-ae7c-46e8-9a78-da6371e7036c"}

Hi @Dwi_Cahyo_Mariyanto ,

I think that device is no longer supported by Rigetti. The best way to access Rigetti devices is via the pennylane-braket plugin. I believe Rigetti has some new devices that are available via Amazon-Braket, although it’s best to check with the Amazon team since device availability changes over time. The Braket team also supports the plugin so you can let them know if you have any issues with it.

1 Like

Hi @CatalinaAlbornoz

Thank you for your answer.
Actually I want to try Readout Error Mitigation from this Readout Error Mitigation Documentation pennylane-rigetti

Is the documentation still valid, because I have problem when running it?

Hi @Dwi_Cahyo_Mariyanto ,

Unfortunately that example is from 5 years ago so we don’t support it anymore. I recommend that you look at the demos from the PennyLane website Demos — PennyLane. There you’ll find supported demos. In case a specific demo only works with an older version of PennyLane it should be clearly marked at the top of the demo.

That being said, note that the pennylane-rigetti plugin is not supported with newer versions of PennyLane so if you want to use Rigetti devices you’ll need to use them via the PennyLane-Braket plugin.