Current location: Homepage > solidity > Artificial Intelligence Full Course 2024 _ AI Tutorial For Beginners _ AI Full Course_ Intellipaat [DownSub.com](1).txt - Ep93

Artificial Intelligence Full Course 2024 _ AI Tutorial For Beginners _ AI Full Course_ Intellipaat [DownSub.com](1).txt - Ep93

2025-07-11 13:28:11 [java] Source: MetaScripta
like or trump vs biden 2024do you think thatwe need to change the target variablehere what do you guys thinkone hot encoding right so we need to doone hot encoding of the target variableso I'm calling the label binarize overhere label binarized is a function youcan use one hot encoder you can usedummy variable encoder whatever thistime we are using label binarized I callthe model object label binarized I fittransform my train data and I fittransform my test data right as soon asI do this I am able to change the shapeof my y train and Y test both right ifyou seey let's say if I show you y train zero ytrain Zer was index six right so you cansee that 0 1 2 3 4 5 six six index isactually one over here right this wasrequired uh because our Target variableuh this is a multi classificationproblem so we had to pass the one hotencoded values to the model rightthis is just an example so you can seethat the same thing we can do using onehot encoder or pd. getet dumes right wehave used over here a label binarizingright so whatever is whatever you arecomfortable with you can go ahead andyou can use that all right so this isall the pre-processing that we have todo not there is there is no dataexploration no amount of right if you'reable to read the images if you're ableto visualize the images is on python itmeans that they are not corrupt if theyare not corrupt that means that yourdata that your features are correctright and you all you need to do is thatyou need to check how many features inuh or how many samples in the train datahow many samples in the test data whatkind of a Target variable you have doyou need to change the target variableand all so that is what we have donetill now and now we can directly proceedto the model building see Eda and allthis will be minimalistic in case of CNNmodels right but if you try to look atthis from a real world perspectivecollecting data organizing that data allof that is something that will take moretime whereas with structured data youcan just directly go ahead and importthat but structured data accumulation ofstructured data once when you have apipeline will be easy as compared toaccumulation of such unstructured dataright like images videos and all allright so let's proceed to the modelbuilding part now now for the modelbuilding I will be showing you onesnapshot of the model right uh that ishow we can add the different layers andall but I want you guys to then go aheadtake this notebook and explore exploredifferent kinds of models do hyperparameter tuning that is something thatI've already shown you in the case ofAnn right how do we do thehyperparameter tuning so over here aswell I I expect you to do that right Iam showcasing you I am showcasing a verycomplicated model over here right whichwill be using different many convolutionlayers many reu many Max pooling layersand so on and so forth right so let'shave a look at the model the model thatwe are creating will have these manylayers right if you look atthis the first first we'll start with aconvolutional layer of 32 feature mapsof the size 5 cross 5 and a rectifieractivation function this will befollowed by a batch normalization layerright I hope you guys remember the batchnormalization layer what does the batchnormalization layer do it standardizesour data it normalizes our data beforeit is being fed to the different layersright uh we have studied about this inthe Annpart then we are applying one moreconvolution layer 32 feature Mapsfollowed by batch normalization followedby Max pooling followed by Dropout rightso over here as well if you see when adda Dropout of 25% what does that mean aDropout of 25% means that if you have 32feature Maps right out of these 32feature Maps or 25% feature Maps will bedropped off right so over here as wellyou can see that just like in case ofneurons when we were adding dropouts wewere deactivating the neurons over hereif we let's say add 32 filters and wewant to randomly deactivate certainfilter filters and see which filters arecontributing which filters are notcontributing then over here as well wecan add Dropout right so people who areasking questions such as how will weidentify the filters which filters weneed to apply and all the answer is youdon't need to do that this is the partof the model training identifying theimportant features identifying what uhconvolution filters to take what not totake is not your job it is the model'sjob rightthen after that it is followed byanother set of convolution layer 64feature Maps now we have reduced thesize to 3 cross three batchnormalization once again Dropout onceagain convolution with 64 batch normaluh normalization followed by Max poolingfollowed by Dropout then finally we goto Max pooling layer uh then we add thefully connected layer with 256 units weadd Dropout at 50% and and then finallywe have the output layer right so thiswill be the architecture of the modellet's go ahead and have a look at it howit looks when we code this model youcannot arrive at in the first goobviously right you will have to try outdifferent variations differentcombinations so whatever hyperparametertuning we have worked on all of thatwill stand true here as well you willhave to try out different permutationsand combinations and you will have tosee which one is working the best whichone is giving you the best accuracyright so don't think that this issomething that you will arrive at in thefirst go and the second go you willstill have to run tens and 20s ofiterations and see which whichcombination of different layers isactually working the best for youright all right so let's proceed uh theshape of my input data is this is 32A32A 3if you remember this now this is wherewe are uh creating the modelarchitecture right so at first I do notpass any bat size I instantiate themodel if you let's look at this row byrow right

(Editor: news)

Recommended articles
Hot reading