AI for Everyone LESSON 4: Installing and Configuring Visual Studio Code on Windows 10

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello guys this is paul mcquarter with toptechboy.com and we're here today with episode number four in our incredible new tutorial series where you're gonna learn artificial intelligence or you're gonna die trying what i'm going to need you to do is for yourself a nice cup of iced coffee that is straight up black coffee poured over ice no sugar no sweeteners none needed now as you're getting your coffee poured as always i want to give a shout out to you guys who are helping me out over at patreon it is your support and your encouragement that keeps this great content coming you guys that are not helping out yet look down in the description there is a link over to my patreon account think about hopping on over there and hooking a brother up but enough of this shameless self-promotion let's jump in and talk about what we're going to do today and what we're going to do is we're going to see how to install visual studio code on a windows 10 machine why are we doing this this class is about artificial intelligence and as we move forward in the class your life is going to be easier and my life is going to be easier if we are operating on the same integrated development environment and even better if we have that ide configured the same so even if you have visual studio code i hope you'll watch this lesson so that we end up with systems that are in sync with each other and it just makes things a whole lot easier guys you've been really patient with me this is what lesson four and in these lessons we've had to lay some groundwork we've had to do some build a foundation for the work in lesson number two i showed you how to operate on multiple versions of python on the same computer and then last week what i showed you is in lesson number three i showed you how to work with python virtual environments as we get into artificial intelligence you got to kind of have some of that background knowledge with python to be successful and then what we'll do today is install visual studio code i promise you guys next lesson lesson number five we'll get into the really fun stuff and the cool stuff and we'll actually jump into opencv and you'll be able to launch your webcam and show videos on your screen start doing things like that so if you have not ordered your webcam yet look down in the description there is a link over to the identical logitech webcam that i'm using and if you use the same webcam that i am using you will get the same result that i'm using but if you have some old laptop with some random laptop with some random uh camera on it i don't know i don't know if you'll get the same result as i you can try but the safest thing is if we have the same system and we have the same hardware okay enough of this banter in chit chat in introductory nonsense let's jump in and let's get this job done okay what i'm going to need you to do is i'm going to need you to switch over here and i will get out of your way and i need you to launch a browser and i like to use the most excellent duck.go and what we are going to search on is we are going to search on download visual studio code download visual studio code and we get this first result back download visual studio code it is at code.visualstudio.com slash download we will click on that okay we are operating on windows i am on a 64-bit windows machine and i want the user installer so for me i'm the upper left of the kind of nine blocks there i'm on 64-bit user installer i will click on that and when i click on that we should be seeing here very quickly the happy little download icon showing that it is downloading visual studio code i do not have a really fast internet connection today so it will take a second and then as soon as it downloads what we will do is we will install and boom we have the happy little blinking visual studio icon indicating that the installer has successfully downloaded we are you guessed it we are going to click on that bad boy and the installation should start very shortly have a sip of coffee okay the installer is running it's asking us to accept the agreement have you ever actually read the 27 000 pages of what we are actually agreeing to i have no idea i could be giving away my first born child and my left kidney for all i know but we will go ahead and live dangerously and we will click next and then it says setup will install visual studio in this folder the default folder is fine so i'll say next and then it will put it in the start menu that's fine i will say next and then here you do want to make sure that you have this checked where it says add to path you want a check mark in the box next to add to path and i am going to create a desktop icon just because i can and then we're going to click next and then it's ready to roll and so we are going to click install and we are off to the races have the happy little green bar going across there that is what we like to see and this thing should be done in lickety-split no time at all boom okay we've got the check mark here to launch visual studio code and so we will go ahead and click finish and this baby should launch all right boom there we have it it is up and now what we need to do is we need to take a minute to configure it and so we are going to configure it for python and let me see if i can do a little windows management here so i have it where you can see it i hate it when it does that i want to set the size microsoft i don't want you to set the size and you know i am obsessive compulsive about getting it perfect but ah that's not too bad okay we got it pretty quick there so now there's a couple of things that we need to do we need to now configure this for python so we're going to come over down here to the this lower icon which is the little blocks and we're going to click on that and we need to install the python extension so i'm going to say python and then it finds the python my first result is python intellisense pylance linting and debugging so i will click install and now it will take a second to download this and install and what uh what this is is these are just kind of add-ons to python this is not python itself now what you have to understand is python does not come with visual studio code if you were with me on lesson number two in this class we installed python 3.9.6 and 2.7.9 or 3 3.9.6 and 3.7 so we have two versions of python already installed on our system and what we can do is we can use either one of those if you have not installed python yet the python interpreter the python application you need to go back to look lesson number two and you need to do that lesson or you need to install python on your own because understand python does not come with visual studio you point visual studio to the python that you have already installed okay and we now have the happy little check mark by installed and so that is done and that looks good so now we have the python add-ons that are helpful for us to use in visual studio now one of the really nice things about this is is that it is this intellisense and what intellisense does is intellisense gives us helps and hints as we're typing code and so like if opencv has all these different parameters it sort of reminds us of what our options are it's a really useful thing to have installed [Music] okay now what i want to do is i want to configure it where it looks the way i like it and so i'm going to come up to file and i'm going to come down to preferences and i'm going to come over to color theme you guys can play around with the color theme that you like some people like white background some people like dark backgrounds i really like the monarchy i really like the mana case so i'm going to select that and that looks pretty good i like as we start coding the kind of like highlighting colors it uses you can play around and use the one that you like the bat best but this is the one that i'm using okay now we have to take visual studio code and we've got to point it to the version of python that we want it to run so we do that by clicking all together control shift and p as in paul ctrl shift p and we get the search bar and then we need to search on python and then you need to put a colon in in a space and then s for select select and then you can see it gives me the option of python select interpreter that's what we want to do so we'll click there and it's out looking for python on my system right now seeing what is there and this is what it found it found what we installed in lesson number two python 3.9 0.6 and 3.7.9 now why did it find those two versions of python because when we installed them we added it to the path there was that little check mark when you install python you say add python to path and so these two versions of python are in my windows environmental path and therefore visual studio code was able to find them so let's just come up and say let's run python 3.7.9 just for fun and then we're going to come over here and click on this little double page icon like that and what you can see is is now you've got to tell visual studio code where you're going to be working where you want to save your files where you want to save your programs and so we need to point it to a folder to work in a working folder and so what i am going to do is i am going to come down to my little windows file browser and i'm going to go to documents and you can see that what was it last week or week before we created this python folder inside my documents folder you can work in whatever folder you want but it might be useful to create a python folder you could do that here by right mouse clicking let's do it over here right mouse clicking and say new folder and then rename it python okay so you should be able to do that that's no great mystery how to do that so i'll close this now i'm going to file and i'm going to open folder now i could just click open folder here but next time it might not be there so you need to see that you can do it here file and open folder and where do i want to go i want to go back to documents and then there is our friend mr python folder and so i clicked on it i'm now inside that python folder but now i just say select folder and it will open that up it asks me do i trust the author i'm the author yes i trust myself i'm not some sort of schizophrenic confused or something yeah i did it i trust myself okay i'm going to make this where it is a little bit easier for you to see okay now i will come and i want i want to uh let's see did i set the did i set the color already i don't think i have so i'm going to come and i'm going to say file and i am going to say preferences and i'm going to say color theme yes i did i am going crazy i might not be schizophrenic but i am going crazy and then what i'm going to do i set that i'm going to make the font bigger for you so i'm going to come to file i'm going to come to preferences and i am going to come to settings and then i am going to come to over here text editor and then i'm going to come to font and i'm going to give you a 28 point font now you can set yours however you want it like normally i probably wouldn't use a font this big but the thing is is that so you can see it as i'm tapping i make it a little bit on the large side now i'm going to click off of that just click somewhere else and now i'm going to close those settings and i'm going to close these settings so i got all that closed so now i am ready to create a program i better delete this one that i done earlier on the dry run and so now i'm up here in python okay and now i'm going to click the plus here and then let's see give me just a second here close that okay now i'm going to click the plus and this will create a new file inside of this will create a new file inside of this folder and i can say that this is hello world and dot p y the dot p y is kind of important because that my friend that dot p y will tell it that it's a python program and so boom there it is now we can just say print and we can print hello world like that and now to run it we come up here and we run it and it is taking a freakishly long time to do it okay there it is boom hello world okay but what i want you to see is is that it in fact what is it running it is running python and then it is running python37 why because that is the interpreter we selected now i can do i could select a different one but now this is something i want to show you the first time we did the control shift p what did it find it found two python interpreters 3.7 and 3.9 why in lesson number two we'd installed those two python interpreters we had put them in the path when we did the installation so it offered me two choices now i want you to look and if i do ctrl shift p what happens for you i'm going to go ahead python select interpreter depends a little bit on whether you did lesson 2 and lesson 3 with me but for those of us that did lesson two in lesson three remember what we did in lesson three we put in two python virtual environments and so now you can see that in my choices of python interpreters i not only have this 3.9.6 and 3.7.9 but i also have 3.9.6 in the virtual environment and 3.7.9 in the virtual environment so now instead of just running these main interpreters i can run inside of a virtual environment and so let's just click this python ai 3.9 that was the virtual environment that we set up last week now if you take the class you will have if you took lesson number three you'll have it if you did not take lesson number three you won't have it but now i'm going to come in and so now i'm going to run it and this time if you will look i will need to move this up where you can see it okay if you look now i'm running python and i am running a i 3.9 so now i am running in the virtual environment okay so you see you don't even have to go in and activate that virtual environment you can run it just by pointing uh visual studio code to your virtual environment okay guys this has been a pretty quick lesson it's been a pretty easy lesson but what we've done is we've now kind of gotten things configured to actually start the artificial intelligence work so next week i promise you in the next lesson lesson number five the fun stuff starts the magic starts happening so be sure to tune in next week really appreciate that you were patient with me but man i just didn't want to go through this and have you trying to follow along without really understanding what you're doing so if you've watched these lessons you know how to run multiple versions of python on the same computer you know how to work in virtual environments and you know how to work in visual studio code and you know how to point visual studio code to either main python installations or virtual environments and so you really have a pretty nice tool set to move forward into actually starting to code artificial intelligence okay don't really have any homework for you this week i always like to give you homework never fear next week you will start having homework but what i will do is i'll give you a secret word if you want me to give a little heart by your comment you need to give me a secret word that shows that you have watched the video all the way to the end and what the secret word is banana you see these bananas i grew those bananas myself yes i grow bananas i have a little bit of a banana plantation and i have my banana trees staged where i get a nice bunch of them getting ripe every day so i am like i have an abundance of bananas and so the secret word is banana okay guys i hope you all are having as much fun taking these lessons as i'm having making them and if you enjoy the lesson be sure to give us a thumbs up make sure that you put the secret word as a comment down below so i can give you a thumbs up a little heart on your comment and then also if you haven't subscribed to the channel already make sure you hit that subscribe button when you do make sure you ring that bell so that you will get a notification anytime the old top tech boy posts a new lesson or a new video and think about sharing this with other people on your social media share it because we need more people doing useful things like coding and engineering and fewer people sitting around doing silly things like watching silly cat videos paul mcquarter top techboy.com i will talk to you huckleberries later [Music]
Info
Channel: Paul McWhorter
Views: 11,385
Rating: undefined out of 5
Keywords: Artificial Intelligence, AI, Python, STEM
Id: jyW7zUlvz3o
Channel Id: undefined
Length: 19min 41sec (1181 seconds)
Published: Fri Jul 30 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.