I don’t see a category for “Challenges” but I assume the discussion forum is the right place to post this.
I just completed the recently-released “PennyLane Certificate Challenge” and noticed there’s a small issue that might be worth correcting or clarifying.
The function W takes as an input the params, which are supposed to be typenumpy.array according to the function’s documentation. However, the grader actually checks W on its own, but passes an argument of type list instead of numpy.array. This will throw an error if you try to use, for example, params.shape to get the shape of the matrix.
Same is true for param_set used by quantum_model.
This is usually not a big deal but I though I would bring it up because it did take me a little while to figure out where to make changes because I didn’t realize W is being checked by the grader individually.
Hello, jumping onboard for Pennylane from earlier IBM-Qiskit challenges, and missing a bit the discord-server discussion boards …
So I taking this post as beginning of a “Certificate Challenge” Thread if you don’t mind.
Now, I wonder what I got wrong in the definition of Sin def S(g, x, num_wires):
Having spent some hours now, I found different ways that failed , and finally one that I used resulted that I pass the public test (yay!), but … I do fail the private test.
Any hint what is behind the private test would be helpful.
I did have to check in an IF-statement if the g is PauliX or PauliY - and then assign the function, then it works, without the IF, it does not work ?
I do not want to spoil with my solution - I first replaced it with RX and RY etc. and then ended currently with qml.exp(...) of g(wire) and coeff of 1j*x?
If there is any other way (or maybe I am wrong and do not know the right way?) to get insight or a pointer to a docu for me to learn what else I can do would be appreciated.
Since this challenge earns you a certificate, we can’t help you with it much. It’s likely that your code does not solve the challenge in full generality. You are welcome to discuss with other people in the #pennylane-challenges channel in the Xanadu Public Slack. Maybe someone can give you a pointer in the right direction!
Yes, thanks and sorry for the late answer, I had used a coincidence where the composition of the overall circuit was wrongly indexed in my loop. Doing the loop correct it worked.