IBM Q Experience specifying the "Session_ID" or "Tags"

Dear Pennylane developers,

Recently, I was using IBMQ Experience through pennylane-qiskit plugin. I notice that when I look at my “Jobs” at the IBM Quantum Platform (Jobs | IBM Quantum Platform), there are “Session_ID” and “Tags” columns (please see the figure below). I was wondering if there is any way using pennylane to specify these two values without using qiskit. Thanks a lot in advance! :slightly_smiling_face:

Hi @Yian_Chen, thank you for your question!
It’s good to see you here in the forum.

I don’t see how you could do this at the moment but I will mention it to PennyLane developers to see if we can include it in future versions of the plugin.

Alternatively, if you just need it for yourself but you don’t care whether it appears on the IBM platform, you could set it as a backend option in PennyLane as follows:

dev = qml.device('qiskit.ibmq', wires=2, shots=100, backend='ibmq_qasm_simulator', session_id='test', tags='test_tags')

You can then retrieve this and more information running:

# Retrieve your current job
job = dev._current_job

# Print the job details
print('Details: \n',job.time_per_step())
print('job_id: \n',job.job_id())
print('backend_options: \n',job.backend_options())
print('tags: \n',job.backend_options()['tags'])
print('session_id: \n',job.backend_options()['session_id'])

Again, please note that the tags and session_id will not appear on the IBM platform in this case.

I hope this helps you! And thank you again for your question.

1 Like

Hi @CatalinaAlbornoz , many thanks for the reply and the alternative approach! :slightly_smiling_face:

No problem @Yian_Chen !

My colleague Lillian has made a Pull Request in the PennyLane-Qiskit plugin to allow you include session_id and job_tags in the next release, which will be in early January :smiley:. You can keep an eye on that Pull Request and use it from the development version once it’s merged, or you can wait until the next stable release in January.

Thank you again for bringing this up!

Thank you and all the developers so much for the supports! :pray: :pray: :pray:

1 Like