Machine Learning Interfaces: Which to install?

I am new to PennyLane, and I just finished installing it locally on my computer.

I was wondering which of the machine learning interfaces I should start with as a beginner, I’m looking for ease of access as I get to know the software before I dive in with anything more complicated.

Hi @Joan, welcome to the Forum and to the PennyLane community!

A good place to start is the Xanadu Quantum Codebook where you can learn about PennyLane and quantum computing at the same time. The Codebook uses the NumPy interface, which is the default. However if you want to learn how to use an additional machine learning interface I would recommend PyTorch or Jax.

In pennylane.ai you will find many tutorials, and in the Getting Started category you will find some on how to use different interfaces.

If you prefer videos to learn about PennyLane we’ve got a series of tutorials on YouTube.

I hope this is helpful and please let me know if you have any further questions or thoughts about PennyLane! We’ll be happy to help.

Hi @CatalinaAlbornoz - thank you for the helpful response!

My most recent research has focused on theoretical work understanding Barren Plateaus - so I am excited to introduce the students I am mentoring to something they can code themselves and see the real-world impact of our work in neutralizing such phenomenon.

Thank you for the tips!

Hi @Joan,

This is awesome! Coding something yourself can really make a difference in your understanding of the subject :smiley:.

Regarding the Barren Plateaus, we have two great demos on Barren plateaus in quantum neural networks and Alleviating barren plateaus with local cost functions. They may be good resources for your students to try out!

Please let me know if you have any further questions, we will be happy to answer them!

Thank you for this @CatalinaAlbornoz ~!

I had seen the first tutorial but not the second - this paper on local cost functions was the basis for my master’s thesis at the Institute for Quantum Computing!!!

My thesis:
https://uwspace.uwaterloo.ca/handle/10012/18187

In this work, I proved theoretical results for a VQA I published back in 2018 on Variational Quantum State Diagonalization - I showed that this VQA had a global cost function and then proved that the same algorithm would still work with a localized version.

Now I am tutoring students to expand our analysis to ALL VQAs in the literature! Using this and other papers on barren plateaus we want to perform a comprehensive audit of the field to showcase which of these algorithms can be modified to avoid barren plateaus - and run some numerical simulations to get a feel for their performance.

Thank you again for this resource, I’m honestly floored that you all at Xanadu have tutorials on such pertinent topics to my own work :smiley:

Another resource that I would love to create as a PennyLane tutorial for my students is this recent publication from the same group that produced that cost-function dependence paper:

They explored the relationship between the ansatz and BPs, which is something I haven’t seen implemented as an accessible tutorial as yet!

Oh wow you’re doing some impressive work @Joan! :smiley:

It makes me very happy to hear that you’re getting the most out of our demos.

It would be amazing if you could contribute a tutorial about this paper you shared. You can start by writing it in your own repository and then open an issue here linking your demo. Then we can guide you on the steps to follow!

Please let me know if you have any other questions about this or any other topic.

It’s great to have you here in the PennyLane community!

Ah! This is great!

I am going to see which of my students may want to help me with this - I’m assuming it is possible to list multiple authors on the tutorial?

The reason this is so important is the same as the motivation for the project itself:

When I finished my thesis I could have easily put my head down and churned out the results for the next phase of this project and gotten a nice solo paper on my own. But what matters more to me is that I use this as an opportunity to advance the careers of students from diverse/equity-seeking backgrounds who would benefit much more from getting their name on a first paper to start their careers.

My students come from all over the world, with all sorts of different strengths and challenges, and building a community for them to flourish as part of my larger community initiative the Quantum Ethics Project (https://www.quantumethicsproject.org/) has been some of the most gratifying work of my career.

This issue is personal for me as an autistic, transgender person who spent the majority of her teens homeless in the US - I have a passion for equity and education that comes from lived experience. I want to use this experience to lift up others in my community who need it now that I am in a position of relative privilege at the IQC.

This tutorial will be a great way to build up the CVs of my students!

Also, will I have the opportunity to write the explanation of the code/education portion of the tutorial? I’d like to keep growing my own skills as an explainer/educator of QML :heart:

Hi @Joan, I’m sorry I took so long to reply.

Yes, you can absolutely include multiple authors in the tutorial.

It’s really amazing that you’re helping advance the careers of your students. And thank you for sharing the link to the Quantum Ethics project, it looks like an amazing community. I totally understand the feeling of wanting to give back to the community. I personally feel privileged to be where I am and being able to help people from very diverse backgrounds.

You can absolutely write the code/education portion of the tutorial. I’m eager to see this tutorial and I’d love to see more of your QML educator work :heart:

Happy holidays and I hope we get to talk more next year!