How to Install TensorFlow GPU in Windows WSL2 | Install Anaconda in WSL2 | Using WSL for TensorFlow

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi everyone let's go ahead and see how you can install tensorflow on your Windows system you need to visit tensorflow.org SL install and then forward SL pip you will be coming to this page on this page you will be seeing here a lot of options to install tensor flow on your computer it gives you option to install on Linux Mac OS Windows NAU and windows SL2 these are the two important uh uh link which you need to see so earlier there was Windows net when you can simply install tensor flow with the K on your Windows computer but nowadays you cannot install with this method so this method is applicable only till tensorflow 2.10 and the python 3.10 after that it will not install tensor flow on your windows so what you need to do to install the tensorflow on your machine for that purpose you need to do the setup of Windows WSL so what is this WSL this is a Windows subsystem for Linux that means there is a small service of Linux which will be running on your Windows machine and in that Linux subsystem you will install your pip uh you will install your tensor flow using a pip and then you can use your tensor flow in this we will be also installing the GPU support for the tensor flow and I'll be showing you how you can install this in WSL to so you can simply click on this link this will show you how you can install the WSL for bravy and Clarity I have already installed WSL but if you have not installed WSL you need to open your power cell in your machine and you just simply know need to write their WSL install it will a automatically install Windows subsystem for Linux to you all right so the WSL will automatically get installed so you open here a power cell after opening this power cell what you need to write here you need to write here WSL forward uh double hyphone install so with with this you will see that the WSL will get installed I have already installed so it's going to launch Ubuntu subsystem in my machine instead of installing otherwise it will ask you promt to install it you can follow this step and install this once you have installed WSL you need to come to the anaconda.com you click on free download otherwise you can simply put here download so you will be coming here to this uh uh this page on this page what you can do you can select here Linux all right so after selecting this Linux you need to install 64bit installer I mean you need to download this 64bit installer it's going to download anacona 3 Dosh file there so this Dosh file we are going to install inside our Linux subsystem all right once it is in once it is downloaded we will be going to install it from here but in meantime you can check the uh uh you can check all these uh uh uh the directories which are inside this subsystem so the currently there is no directory inside this subsystem you can come to here again you can open a new power cell you can write here WSL so if you simply write there the WSL a default directory it will open here MNT and then C users and lxmi so you see there this C users lxmi this is a very familiar path which we get in our Windows machine so it has added here by default this MNT which is Mount there so it has mounted C drive users and the LXI inside this if you press LS that is the list directory you will be seeing all these windows folders here you can see the download folder here as well so I write here CD and then downloads I go here inside the download I type here LS I'll be seeing here the Anaconda which we had just downloaded here that is present here so now we need to install this Anaconda here I can simply close this there is no use of that once you have come here inside the download folder where you have downloaded the Anaconda for Linux subsystem you need to first of all update here your subsystem so I write here sudo op get update so the sudo will ask about the password which you have provided earlier for me it is root password your password may be a different so with this index of your Ubuntu subsystem will get updated once this index is updated you need to install here pip as well so that you can install with sudo opt install Python 3 pip so this is going to install pip for Python 3 I have already installed otherwise it will install for you once all these things are done then you can install Anaconda so to install the Anaconda I'm going to write here bass then I write here the Anaconda and then press the tab it will automatically put the file name here therea I provide here the minus B minus U minus P so basically it's going to accept all the license all the default uh setup it is not going to ask anything to us it will simply install Anaconda otherwise there are the license you need to check the path all these steps will get skipped from here I'm going to provide here the default password uh default path where it installs so the default pass path is here the anakonda 3 so the this one is default path to install the Anaconda all right once I do all these steps it is not going to prompt anything to confirm otherwise it is a tedious process it will be asking you a lot of permissions to install this anaconda in your Linux subsystem if you choose this it's going to install it straightforward all right so we are going to wait for some time while it is installing it so installation is finished here as you can check it here okay so it has successfully installed that you can check it here something like this CD and then you you you come here home directory and then you check here LS andaconda 3 is installed here once installation is done now we need to initialize Anaconda to initialize Anaconda we need to WR here we need to go inside the Anaconda so I write here anakonda 3 and thereafter you need to go inside the bin directory and then you need to go inside the k i initialize here the bass profile I need to I I mean to say that I initialized anakonda 3 in bass profile thereafter I'm going to initialize Anaconda for our uh uh the bass profile again here so these two things are done here thereafter we are going to check this bass profile so that we check here the Nano bass RC and you need to come here down just to verify that if it is added here so you Che you can check it here the anakonda path is added in Your Bass profile successfully control and X you can cut that thereafter you need to reopen your uh uh you need to reopen your WSL subsystem here so I just write here again WSL now you can check it here by default this is activated here if you just just uh uh Zoom it a little I type here the K you can check it here the K is installed there I check here the python so the python 3.11 is installed here so currently by the time I'm making this video uh tensorflow GPU does not support python 3.1.5 so what we need to do here we need to install python 3.10 so for that purpose you need to create a new environment which is going to support python 3.10 so here is the command which I have written so basically we are going to install python 3.10 here all right so with this in fact here you need to write python is equal to 3.10 so this python 3.10 will get installed as a new environment and inside that we will be installing tensor flow so it asks about installing all the necessary libraries I say s so it has installed all these necessary libraries and then I activate here python 3.10 thereafter you need to come here and you need to scroll it a little down I'm going to use here pip so I will install it using pip install upgrade pip so this you need to upgrade your pip if you haven't done that so it has installed latest version of pip thereafter for all GPU user I need to copy this from here and then I need to paste it here all right let's go ahead and run this it's going to install all the necessary librar so it seems like uh all these necessary libraries are already installed here if you haven't installed it will ask about you to install these and it will take a little time to install all these necessary libraries so it has successfully installed all the necessary Library thereafter you need to scroll it a little down and then you can verify your GPU setup copy it from here and then paste it here you should be able to see their GPU listing so it will take a while to show you the GPU so it says that these GPU devices is available here inside inside my python 3.10 environment so we have successfully installed GPU here let's go ahead and see now how you can connect your windows Linux subsystem with your traditional Windows machine so there is no difference here basically you can uh uh you you can go inside the download directory here if you want to go and then you can install here your Jupiter notebook like you used to do something like this so it says that Jupiter notebook is not found and it is it it ask about to install Jupiter notebook I'm going to install this here since we created here a new uh uh we created here new environment so in that environment notebook was not installed so it will take a take a while to install this so your notebook has installed here let's go ahead and start here Jupiter notebook now it has successfully started here you can copy any of these URLs and you can paste it in your browser where you want to open your notebook I paste it here I can see my notebook has successfully opened in my windows folder so the windows download folder if you open your Explorer you check it here Windows download folder so you can see here svm stepbystep tutorial all these I can open these notebook from here or you can create a new notebook so by default I'm opening here a new notebook like for Vector machine stepbystep classification other than that you can create here a new notebook if you want so it will create here new notebook and then you can run here any uh you know any code you want to import here I mean any code you want to uh any code you want to run it here so by default it says that the pandas is not installed obviously we have created their a new we created their new environment so you need to install pandage there or whatever uh P install pandas or whatever the library you need to use you need to install that before using that all right so that's how you see there and if you want to create if you want to open your vs code Studio with that you can do as well so you want to connect your WSL here and uh if it doesn't connect let say something like this where you have a new uh uh new window where it is not connected so you click on here thereafter you can connect these to WSL it will automatically connect with your WSL otherwise if you want to open any folder in your WSL and uh your folder is inside Windows machine you can simply come here or you can press control shift and P control shift p and then you you type there WSL and then you will see their open folder in WSL otherwise you can write there open folder in WSL so you click on here it will ask you to open any folder in WSL let's say I want to open this svm in WSL I select that it is going to select WSL here there after it is going to open this folder in WSL environment and do remember this file is this file is located in my Windows system so here a kind of you know uh tunneling is being created where your file is stored on your Windows system but your notebook will be using a system which is running on WSL all right so that's how you can use Windows and windows subsystem for Linux together we have successfully installed here tensor flow on Windows wsl2 all right if you have liked this video please subscribe this channel come to my channel kgp talkie here you click on here subscribe this Channel and you can click on here playlist I have so many playlist which you can watch to get started with your machine Learning Journey thanks a lot for watching this I'll see you in next one
Info
Channel: KGP Talkie
Views: 4,462
Rating: undefined out of 5
Keywords: kgp talkie, kgp talkie videos, machine learning tutorials, kgp talkie data science, kgp talkie ml, kgp talkie for machine learning, install tensorflow gpu, install tensorflow gpu windows 11, install tensorflow gpu in wsl, install tensorflow windows wsl, tensorflow in wsl2, how to use wsl2 on windows 11, use wsl2 for deep learning, use vs code in wsl2, install tensorflow in wsl2, install anaconda in wsl2, install tesorflow in wsl, install tensorflow in linux wsl
Id: OHCPGvf06EA
Channel Id: undefined
Length: 15min 22sec (922 seconds)
Published: Sat Oct 28 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.