Тёмный

Hello World | Coding with Qiskit 1.x | Programming on Quantum Computers 

Qiskit
Подписаться 152 тыс.
Просмотров 36 тыс.
50% 1

Опубликовано:

 

28 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 121   
@remingtonsmith1372
@remingtonsmith1372 4 месяца назад
Some lingo that may be useful! 1. Bell State A Bell state in quantum computing is a special type of entangled state where two qubits are linked such that the state of one qubit instantly influences the state of the other, no matter the distance between them. 2. Superposition The principle that a qubit can exist in multiple states (0 and 1) simultaneously, rather than being in a single state like a classical bit. 3. Hadamard Gate A basic operation that transforms a qubit into an equal superposition of its 0 and 1 states, creating a state where the qubit has a 50% chance of being measured as 0 and a 50% chance of being measured as 1. 4. The CNOT (Controlled NOT) Gate
A two-qubit operation where the state of the second qubit (target) is flipped if the first qubit (control) is in the state 1, otherwise, the target qubit remains unchanged. 5. Pauli Operators A set of three basic matrices (Pauli-X, Pauli-Y, and Pauli-Z) used to describe quantum gates that can change the state of a qubit by flipping its state, rotating it, or inverting its phase. In quantum computing, operators like ZZ, XX, and YY perform specific transformations on qubit states, altering their properties such as phase, amplitude, or entanglement.
@DerekWangIBM
@DerekWangIBM 4 месяца назад
Very helpful, thanks!
@qubitevo
@qubitevo 3 месяца назад
Thank you, I had no prior knowledge
@dlcrdz00
@dlcrdz00 3 месяца назад
Appreciate these definitions. I am a beginner and every little "bit" helps. Thank you!!
@georgeliu3028
@georgeliu3028 Месяц назад
Well Explained.🎉
@K.V.A
@K.V.A 14 дней назад
Thank you very much I would like to know how you got to know all this
@tinto278
@tinto278 4 месяца назад
I was expecting the Qubit's to print "Hello World" 😂 Man it looks like I have a lot to learn.
@mragul293
@mragul293 3 месяца назад
😅 mee too
@yuanyangdeng
@yuanyangdeng 2 месяца назад
hahaha
@Ibbysz
@Ibbysz 4 месяца назад
Starting to see how I sound to my parents when explaining classical computing 😭
@storksforever2000
@storksforever2000 Месяц назад
Has "EstimatorV2" been changed? Im getting issues with the arguments
@socratesuffer2765
@socratesuffer2765 2 месяца назад
How to open Conda terminal on visual studio ? I always get powershell !
@bloomdancer736
@bloomdancer736 2 месяца назад
me too
@socratesuffer2765
@socratesuffer2765 Месяц назад
@@bloomdancer736 any luck figuring it out ?!
@Destabilizator
@Destabilizator 2 месяца назад
I'm a little confused, in John's learning videos he says he's gonna use Qiskit notation and says "turn the circuit diagram 90° clockwise to easier remember which qubit is the first" but applying that here q1 would be the first, q0 second 🧐
@chamodhdabarera5904
@chamodhdabarera5904 18 дней назад
Hey derek, I followed the exact some codes. but when following the second example, i got stuck in the 'execute on the backend' part. in their an error message came for the line 'options.dynamical_decoupling.sequence.type = "XY4" ' . the error message was 'AttributeError: 'DynamicalDecouplingOptions' object has no attribute 'sequence'. how to fix this problem?
@dlcrdz00
@dlcrdz00 3 месяца назад
Dr. Wang, I really appreciate you taking the time to create this video series. I am new to Quantum Computing and a little intimidated at the same time. I have a background in Python programming so it makes it a little easier to understand. However, in Step 3, I am getting a Name Error that 'job' name is not defined, did I forget to install something? job is not a variable I thought.
@dlcrdz00
@dlcrdz00 3 месяца назад
Nevermind...I figured out what I did wrong. Thanks for making me work for it...haha
@rohitptnk03
@rohitptnk03 2 месяца назад
@@dlcrdz00 what did you do wrong?
@DaniyaalFarooqi
@DaniyaalFarooqi 2 месяца назад
i have this problem too edit nevermind lol its just the . to =
@marekhubka2887
@marekhubka2887 5 месяцев назад
Hey, is there any detailed class on operators or some other resource? That is one part I cant still wrap my head around.
@kelleclark4521
@kelleclark4521 3 месяца назад
lecture 5 for Pauli matrices (operators) and lectures 6 - 8 help with the gates ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-sCvLwKysdYk.html
@yelakabebe8239
@yelakabebe8239 3 месяца назад
my plot do not match with the one in the video. where is the problem arising?
@martinbombardelli1324
@martinbombardelli1324 5 месяцев назад
I did't get why we are intoducing operators and not just running the qc to get 50% |00> and 50 % |11> what are we doing here ?
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
Sure, one could do that too. In fact, we do exactly what you suggest in an upcoming video :)
@martinbombardelli1324
@martinbombardelli1324 5 месяцев назад
@@DerekWangIBM Can't wait to see it, i'm trying to get a grasp of qiskit but there is son few documentation on version 1.X (except official one of course)
@jm76430
@jm76430 4 месяца назад
it would be excellent if the folks doing work in the quantum space would stop naming things after themselves and instead give them descriptive names.
@phx__7
@phx__7 3 месяца назад
please maximize the vsc window, because the font is too small. otherwise the video is great! thankyou
@ghillesainouche3329
@ghillesainouche3329 2 месяца назад
am I the only one that got constant plot for the 100 qbit case ?
@mistafishman
@mistafishman 2 месяца назад
Same here
@StifTyler
@StifTyler 2 месяца назад
here as well
@mistafishman
@mistafishman 2 месяца назад
@ghillesainouche3329 and @StifTyler I re-downloaded and ran the code from the github and it ran it on ibm_sherbrooke and got a result. I wasn't the same as in the video but it was similar and was not a flat line.
@hvzee1796
@hvzee1796 3 месяца назад
At 21:35 i get the following error: ValueError: cannot create object arrays from iterator
@kutubkhanbhatiya4573
@kutubkhanbhatiya4573 5 месяцев назад
When I tried to run the estimator part of the code it is showing that qc is not defined, why is it happening, is it because I refreshed the VS Code, because when I again run all of the code from the start it works
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
Run the block that defines the `qc` before trying to pass it into the Estimator.
@kelleclark4521
@kelleclark4521 3 месяца назад
since I restarted the kernel after doing the pip install qiskit_aer at this point, I had to run all to get the variables back
@sachinpathak8935
@sachinpathak8935 5 месяцев назад
Sir, When i am to do: from qiskit import IBMQ this is showing error "ImportError Traceback (most recent call last) Cell In[6], line 1 ----> 1 from qiskit import IBMQ ImportError: cannot import name 'IBMQ' from 'qiskit' (C:\Users\sachin.pathak\AppData\Local\anaconda3\Lib\site-packages\qiskit\__init__.py)" even I have upgraded my qiskit to new version. Please suggest.
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
The module IBMQ does not exist in Qiskit I believe. If you're trying to access providers and backends, you'll need to `pip install qiskit-ibm-runtime`.
@sachinpathak8935
@sachinpathak8935 5 месяцев назад
@@DerekWangIBM thanks for your reply. I already have installed ibm run time in my system still it is not working.
@antoniothomacelli
@antoniothomacelli 3 месяца назад
Thanks for share
@CaceresHoracio
@CaceresHoracio 5 месяцев назад
great!!
@doug964
@doug964 3 месяца назад
Great Video, Running into an issue here, from qiskit_ibm_runtime import EstimatorV2 as Estimator from qiskit_ibm_runtime import EstimatorOptions options = EstimatorOptions() options.resilience_level = 1 options.optimization_level = 0 options.dynamical_decoupling.enable = True options.dynamical_decoupling.sequence_type = "XY4" Estimator = Estimator(backend, options=options) job = estimator.run([(qc_transpiled, operators_transpiled_list)]) job_id = job.job_id() print(job_id) TypeError: BaseEstimatorV1.run() missing 1 required positional argument: 'observables'
@doug964
@doug964 3 месяца назад
Sol: Estimator was lower case, correct syntax is from qiskit_ibm_runtime import EstimatorV2 as Estimator from qiskit_ibm_runtime import EstimatorOptions options = EstimatorOptions() options.resilience_level = 1 options.optimization_level = 0 options.dynamical_decoupling.enable = True options.dynamical_decoupling.sequence_type = "XY4" Estimator = Estimator(backend, options=options) job = Estimator.run([(qc_transpiled, operators_transpiled_list)]) job_id = job.job_id() print(job_id) hope this helps!
@CodeSciMath
@CodeSciMath 3 месяца назад
This video assumes you already know .... its not beginner friendly
@superfluous5162
@superfluous5162 2 месяца назад
You are here to learn qiskit and obviously they assume you know little quantum physics alredy .
@michaelcharlesthearchangel
@michaelcharlesthearchangel 5 месяцев назад
You all would benefit from watching my RU-vid videos where I trained ChatGPT on my Quantum Language Model.
@jreamscape
@jreamscape 3 месяца назад
bruh
@mahanahmadi-jd3gp
@mahanahmadi-jd3gp 2 месяца назад
why the last plotting takes too many minutes for me to be executed? , I stopped it. I think the problem is with job.result()
@vishalBaid
@vishalBaid 2 месяца назад
I continue execution of last step for more than 5 mins. But no output. Compare the code. But No Luck. Did you get any solution.
@renatevankempen65
@renatevankempen65 4 месяца назад
Thank you so much for the clear explanation, making it easy to follow and working on my end as well. I've now completed my very first job on the IBM quantum platform 🙂! Will definitely continue with this series and enhancing my quantum knowledge.
@DerekWangIBM
@DerekWangIBM 4 месяца назад
This is great to hear!
@felipefernandesfanchini6094
@felipefernandesfanchini6094 5 месяцев назад
Nice to see new videos for qiskit 1.0 . Congratulations!!! But, instead of the estimator, how to calculate the count to create the histogram, as was previously done with get_counts?
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
You can use Sampler instead. I will show how this can be done in a future video dedicated to Primitives.
@oluwapelumiolubayo2043
@oluwapelumiolubayo2043 5 месяцев назад
Great video! I am also getting stuck on how to implement get_counts on the new version
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
@@oluwapelumiolubayo2043 See the next episode on Primitives, where I show how to get counts with SamplerV2
@mikecole2837
@mikecole2837 4 месяца назад
The only thing I've learned in this video is that quantum software is in its infancy.
@calcifer464
@calcifer464 3 месяца назад
@Qiskit Why didn't he put other Pauli operators like "YY = Pauli('YY')" ? Excellent video, thank you very much!
@Hirdayanshkanojiya
@Hirdayanshkanojiya 5 месяцев назад
Sir i have problem with installation process it just shows my name of pc in terminal anad when i try to create another environment for anaconda(like u) it just shows an error. Can you please help me to resolve my issue?
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
It sounds like `conda` is not active. See if it's installed by typing `conda --version` in your terminal. If conda is indeed there, try activating it: `conda init`. When conda is active, you should see (base) before your username. Once it's active, you should be able to create an environment within conda.
@HrvojeKalic
@HrvojeKalic 5 месяцев назад
Happened to me also. You have to start your terminal in "MiniConda mode". Go to Start Menu and type 'Anac' and there should be something like "Anaconda Prompt (miniconda3)". Start that command/script/program. Someone smarter than me should know how to do this in the VS Code.
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
@@HrvojeKalic Thank you! I only showed installation on Mac in the video. Glad that differences with PC could be resolved here.
@Hirdayanshkanojiya
@Hirdayanshkanojiya 5 месяцев назад
@@HrvojeKalic thank you sir i will try and see if the problem is solved or not
@Hirdayanshkanojiya
@Hirdayanshkanojiya 5 месяцев назад
@@DerekWangIBM thanks sir
@you_know_who5036
@you_know_who5036 2 месяца назад
It shows an error name ‘job’ is not defined
@DaniyaalFarooqi
@DaniyaalFarooqi 2 месяца назад
same
@DaniyaalFarooqi
@DaniyaalFarooqi 2 месяца назад
nevermind lol i didnt catch him change the . to =
@Destabilizator
@Destabilizator 2 месяца назад
@@DaniyaalFarooqi Right? Only your comment made me unpause and look further :))
@shira-cd9hn
@shira-cd9hn 3 месяца назад
hello, im facing an error in step -2 transpilation at 18.23, the error shows : raise AccountNotFoundError("Unable to find account.")
@adamsmyth7101
@adamsmyth7101 3 месяца назад
I know this is very late but you need an IBM account to access their backend
@jorgeas
@jorgeas 4 месяца назад
In Step 3 for the n-qubit GHZ state, I'm getting this error: ValueError: cannot create object arrays from iterator The line causing the error is: job = estimator.run([(qc_transpiled, operators_transpiled_list)])
@DerekWangIBM
@DerekWangIBM 4 месяца назад
The Estimator().run() functions expects `qc_transpiled` and `operators_transpiled_list` to be lists, not iterators. So make sure you've actually instantiated these variables as lists.
@jorgeas
@jorgeas 4 месяца назад
@@DerekWangIBM The thing is, I followed exactly every step. The cell where these variables are defined run well. The other one does not. Not really sure what am I missing here. def get_quantum_circuit(n): qc = QuantumCircuit(n) qc.h(0) for i in range(n-1): qc.cx(i, i+1) return qc n = 100 qc = get_quantum_circuit(n) # qc.draw(output='mpl') from qiskit.quantum_info import SparsePauliOp operator_strings = ['Z' + 'I' * i + 'Z' + 'I' * (n - i - 2) for i in range(n - 1)] print(operator_strings) print(len(operator_strings)) operators = [SparsePauliOp(operator_string) for operator_string in operator_strings] from qiskit_ibm_runtime import QiskitRuntimeService from qiskit.transpiler.preset_passmanagers import generate_preset_pass_manager backend_name = "ibm_brisbane" backend = QiskitRuntimeService().get_backend(backend_name) pass_manager = generate_preset_pass_manager(optimization_level=1, backend=backend) qc_transpiled = pass_manager.run(qc) operators_transpiled_list = [op.apply_layout(qc_transpiled.layout) for op in operators] from qiskit_ibm_runtime import EstimatorV2 as Estimator from qiskit_ibm_runtime import EstimatorOptions options = EstimatorOptions() options.resilience_level = 1 options.optimization_level = 0 options.dynamical_decoupling.enable = True options.dynamical_decoupling.sequence_type = "XY4" estimator = Estimator(backend, options=options) job = estimator.run([(qc_transpiled, operators_transpiled_list)]) job_id = job.job_id() print(job_id)
@fayazfreestyle
@fayazfreestyle 2 месяца назад
Sir, it shows error when importing qiskit_aer.primitives How can i solve this
@kmunson007
@kmunson007 Месяц назад
Same error here - says Module Not Found but I can see that it is installed (pip list) and I know that I am in the same environment in VSCode (cwq). Been working this issue for a couple hours now. Still nothing.
@ravijha7301
@ravijha7301 4 месяца назад
Hi Derek, great video and initiative! I attempted to implement a 5-qubit GHZ example on IBM Kyoto, but I received a warning that the task would take more than 10m to execute. Surprisingly, when I tried the same on IBM Brisbane, it completed in nearly 50 seconds. This compels me to ask: How can I determine which system is more suitable for a particular task? Many thanks in anticipation.
@DerekWangIBM
@DerekWangIBM 4 месяца назад
Unfortunately, I don't think there's a feature for estimating resource cost, especially on a device by device basis, until after you submit.
@Destabilizator
@Destabilizator 2 месяца назад
You can dynamically select the least busy resource (although I think it ignores some QPUs available). service = QiskitRuntimeService() backend = service.least_busy(operational=True, simulator=False) All the free QPUs are Eagle r3 (at the time of writing this), on some there's huge queue of jobs, delaying your run
@arvindjain3208
@arvindjain3208 5 месяцев назад
Hello sir I love this series so knowledgeable and amazing sir can I join ibm quantum as a student
@devanshjaiswal9502
@devanshjaiswal9502 5 месяцев назад
You can visit the IBM quantum website, look for a careers page, and you might find something that interests you , you can apply there
@Yaddu143
@Yaddu143 4 дня назад
Thank you
@shanthoshs877
@shanthoshs877 Месяц назад
How to save the program sir
@calvndexter77
@calvndexter77 20 дней назад
Hi Derek, can you help me out? I'm a beginner learning Quantum Computing and Qiskit. I've followed all the steps prescribed in this video. But, at the end, my scatter plot gives me a Straight Line instead of a scattered one as seen in the video. Can you tell me why this happens or what possible mistake I would've done?? Thanks in Advance!
@黄子文-m2m
@黄子文-m2m 10 дней назад
me too! i also want to solve this problem ASAP
@mansiraghav8224
@mansiraghav8224 Месяц назад
Hello, can someone help me with the following issues I am facing while running the code? In the extended Hello world e.g. for n qubit GHZ state, at step 3: for this "options.dynamical_decoupling.enable = True" line of code I'm getting the error "'bool' object has no attribute 'enable'".. even if I comment it out and run the code it is showing similar error in the very next line. Please tell me why this is happening and how I can correct it.
@georgeliu3028
@georgeliu3028 Месяц назад
Great Lesson.❤❤❤
@donabarot9453
@donabarot9453 Месяц назад
I am working on windows and for some reason i wasn't able to create a separate environment, hence I didn't bother and continued with my default setup in vs code jyupter nb. I want to know if there will be any drawbacks of doing so.
@AlexanderNachtigall
@AlexanderNachtigall 4 месяца назад
Awesome Derek, a fantastic Qiskit Intro! Well done and keep going compiling the tutorials in the same style... really appreciated the condensed and swift walkthrough the code and step by step instructions... 👍
@HAKIMA_HAMID
@HAKIMA_HAMID 5 месяцев назад
Sir can you please try the bb84 simulation using qiskit ?
@toobaqasim3300
@toobaqasim3300 4 месяца назад
I am looking for BB84 simulation on Qiskit.
@GiulianoArtale
@GiulianoArtale 4 месяца назад
Hi, thanks for these lessons! They are incredibly useful. I have a quick question, when we initialized the two qubits q0 and q1 are they automatically in the |0> state? (are they both in the same state..?)
@DerekWangIBM
@DerekWangIBM 4 месяца назад
The convention is to assume that the qubits start in the 0 state. For the two-qubit example, we then apply a Hadamard gate to the 0th qubit, so it would no longer be in the 0 state.
@마루나라-n7s
@마루나라-n7s 5 месяцев назад
Hello, I have an error saying that I am unauthorized with the code 'backend=QiskitRuntimeService().get_backend(backend_name)'. (16:40) Can you help me? Thanks!
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
It's possible you do not have access to that particular backend that I use in the video. Use a backend that you do have access to.
@Qubit313
@Qubit313 2 месяца назад
@@DerekWangIBM Sir I'm having the same issue. How am I supposed to get access to a particular backend?
@Tomas-zv2js
@Tomas-zv2js 3 месяца назад
Whenever I type in qc.daw() my circuit is not drawing. Please help
@RenderedUselessness
@RenderedUselessness 3 месяца назад
qc.draw()
@Tomas-zv2js
@Tomas-zv2js 3 месяца назад
@@RenderedUselessness Thabk you!
@techjunk8467
@techjunk8467 5 месяцев назад
Is the transpiling section you used specific for the ibm_brisbane backend? Or can it be used for any device
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
It should work for any backend, as long as you swap out the backend name "ibm_brisbane" with your target backend. Some of the information being sent to the preset pass manager includes the coupling map, native gates, and number of gates, and these properties can of course change from device to device.
@techjunk8467
@techjunk8467 5 месяцев назад
@@DerekWangIBM QiskitError: 'Number of qargs does not match (2 != 100)' I keep having this error from the operators_transpiled_list. What could be the issue?
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
@@techjunk8467 It appears you did not create operators with 100 qubits. Instead, you are applying a layout for 100 qubits on observables that have 2 qubits, which are likely leftover from the initial 2-qubit example.
@마루나라-n7s
@마루나라-n7s 5 месяцев назад
what extensions did you install for putting colors in the code?
@DerekWangIBM
@DerekWangIBM 5 месяцев назад
I'm using the default dark color theme in Visual Studio Code.
@마루나라-n7s
@마루나라-n7s 5 месяцев назад
@@DerekWangIBM I mean your QiskitRuntumeService is written in nice green color which is readable, but my code is all shown in white🥲
@마루나라-n7s
@마루나라-n7s 5 месяцев назад
@@DerekWangIBM I was wondering about the color of the code because I can see nice readable green color from your library code but not in mine.
@Abhigyan103
@Abhigyan103 5 месяцев назад
What is pauli ?
@GabrielTravaioli
@GabrielTravaioli 5 месяцев назад
Pauli is referred to matrices, specif a set of three 2 × 2 complex matrices that are Hermitian, involutory and unitary.
@SiddharthSharma360
@SiddharthSharma360 5 месяцев назад
Rather ask who is pauli
@Aaditya_Kumar_2004
@Aaditya_Kumar_2004 4 месяца назад
On running Step 3, job.results(), I was getting error "observable type not supported: " Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings... Please help me out on this one
Далее
Главное рыба есть, а воды нет..
00:54
Watermelon magic box! #shorts by Leisi Crazy
00:20
Просмотров 14 млн
ДЕНЬ УЧИТЕЛЯ В ШКОЛЕ
01:00
Просмотров 1,1 млн
Full Stack Developers will take over. This is why.
11:26
Quantum Computers, explained with MKBHD
18:13
Просмотров 8 млн
How to get a quantum internship.
8:35
Просмотров 51 тыс.
10 weird algorithms
9:06
Просмотров 1,2 млн
Главное рыба есть, а воды нет..
00:54