YOU DID A REALLY REALLY GREAT JOB. Although i am doing something different and more complex but you have given me the headstart that I need. Thank you soo much.
@paragbharadia28952 жыл бұрын
Sir, at 0:46 which software/ide did you open?
@programming_hut2 жыл бұрын
It’s sublime
@Sweety-rx8zq3 жыл бұрын
Why extension is as .h5? Any help would be appreciated
@gloriamasengo Жыл бұрын
Hi can you show me how to display 5 classes not 2, the model is only showing me for 2
@greenheart38803 жыл бұрын
explained it in really easy way THANKS 👍
@egamomusu2 жыл бұрын
Thank you..however the trained model is not available anymore in the given google drive link at the description section. Could you please upload the model again ? Thank you
@andrearomeroramos6586 Жыл бұрын
Hello!!! Could you pass me the code of your model please, the drive link does not work
@Yussel_UG3 жыл бұрын
¡Gracias!
@programming_hut3 жыл бұрын
Thanks 🙏
@swathinagiri300311 ай бұрын
I have used same program but instead of getting output the application is automatically closing
@arushsingh54892 жыл бұрын
Hey! How do I print my predicted label if I don't want to see numerical predictions?
@m.abdullahkamran88052 жыл бұрын
Hey Sir I am getting wrong output from tflite model when I converted it from keras model. Although output is perfectly fine when I use the same input in keras model.
@AtticEdits8 ай бұрын
Me too😢
@yogietrypambudi61873 жыл бұрын
wow what a good idea to using tensorflow for deep learning app android. but i"ve question when you click predict show the number accuracy data. it"s accurate?
@programming_hut3 жыл бұрын
I don't really understood what you meant. I think you want to show the confidence of prediction right ? btw thanks for your compliments ...
@matovushafik23723 жыл бұрын
why is it that my app crashes whenever i click the predict button, anyways, great work, thank you
@jeffr_ac Жыл бұрын
Did It work?
@lavanyal9418 Жыл бұрын
I also have same problem.Did you resolve your problem?If yes please let me know the solution
@islembenamar13552 жыл бұрын
how i can see the label for images ??
@muhammadtalha24933 жыл бұрын
hello sir, when i click the predict button application automatically close will u help ??
@programming_hut3 жыл бұрын
what are inputs and outputs, if its image then what is input image size , if possible can you share code
@muhammadtalha24933 жыл бұрын
@@programming_hut i also train a model on googlecolab with cnn and then convert it in to tflite like the way You told and it happens the same when u clicked the predict button application shytdown
@muhammadtalha24933 жыл бұрын
image size is (200,200,3)
@muhammadtalha24933 жыл бұрын
@@programming_hut from tensorflow.keras.preprocessing.image import ImageDataGenerator from tensorflow.keras.preprocessing import image from tensorflow.keras.optimizers import RMSprop import matplotlib.pyplot as plt import tensorflow as tf from tensorflow import keras from keras.models import Sequential from tensorflow.keras import layers from keras.layers import Dense, Flatten, Conv2D, MaxPooling2D, Dropout #from keras.utils import to_categorical import numpy as np import os from keras import backend as K import cv2 from google.colab import drive drive.mount('/content/gdrive') cv2.imread("/content/gdrive/MyDrive/checkTest/training/diseased/0a01cc10-3892-4311-9c48-0ac6ab3c7c43___RS_GLSp 9352_270deg.JPG").shape train = ImageDataGenerator(rescale = 1/255) validation = ImageDataGenerator(rescale = 1/255) train_dataset = train.flow_from_directory( '/content/gdrive/MyDrive/checkTest/training', target_size=(200, 200), batch_size=3, class_mode = 'binary') validation_dataset = validation.flow_from_directory( '/content/gdrive/MyDrive/checkTest/validation', target_size=(200, 200), batch_size=3, class_mode = 'binary') train_dataset.class_indices model = tf.keras.models.Sequential([ tf.keras.layers.Conv2D(16,(3,3), activation='relu', input_shape = (200,200,3)), tf.keras.layers.MaxPool2D(2,2), # tf.keras.layers.Conv2D(32, (3,3), activation = 'relu'), tf.keras.layers.MaxPool2D(2,2), # tf.keras.layers.Conv2D(64, (3,3), activation = 'relu'), tf.keras.layers.MaxPool2D(2,2), # tf.keras.layers.Flatten(), # tf.keras.layers.Dense(512, activation = 'relu'), # tf.keras.layers.Dense(1, activation = 'sigmoid') ]) model.compile(loss = 'binary_crossentropy', optimizer = RMSprop(learning_rate = 0.001), metrics = ['accuracy']) model_fit = model.fit(train_dataset, steps_per_epoch = 3, epochs = 50, validation_data = validation_dataset) dir_path = '/content/gdrive/MyDrive/checkTest/testing' for i in os.listdir(dir_path): img = image.load_img(dir_path+'//'+i, target_size= (200,200)) plt.imshow(img) plt.show() X = image.img_to_array(img) X = np.expand_dims(X,axis = 0) images = np.vstack([X]) val = model.predict(images) if val == 0: print ("The leaf has disease") else: print ("The leaf is Healthy")
@programming_hut3 жыл бұрын
so did you resized your bitmap accordingly in android studio
@localbus70083 жыл бұрын
Sir i cant find modeltfLite file in your github
@ronixbhaskar82632 жыл бұрын
Which software have been used ??
@Jerrod24443 жыл бұрын
hi sir, how to get my output result if my result is String ?
@shivamdubey47832 жыл бұрын
sir do we need to learn java for this coz i only know python and tensorflow
@programming_hut2 жыл бұрын
Yes basic understanding of java is required
@antapratama47353 жыл бұрын
How to see name output with labels.txt and %predict?
@m.abdullahkamran88052 жыл бұрын
Sir how to normalize bitmap. My model takes pixel values from 0-1 but in android studio when i save image in bitmap it stores values from 0-255 in bitmap. Kindly tell how to covert bitmap values from 0-1.
@Alex-bx6jf2 жыл бұрын
train the model without normalization or you can add pre-processing layers to the model itself during training
@m.abdullahkamran88052 жыл бұрын
@@Alex-bx6jf It is reducing overall accuracy of the model.
@amirayasmine84903 жыл бұрын
thank you so much that was very helpful
@programming_hut3 жыл бұрын
glad you liked it
@Sara-fp1zw2 жыл бұрын
that was nice thankyou!!!
@kirtipatidar2612 жыл бұрын
hey can you tell me which linux-distro do you use
@programming_hut2 жыл бұрын
Linux mint
@ismail_..2 жыл бұрын
Hello sir,Can I use Kotlin language instead of java in tensorflow lite projects?
@programming_hut2 жыл бұрын
Yes
@codewithchando9713 жыл бұрын
How I can Get the Confidence Value of The Prediction? Extra Code that's I need to add?
@programming_hut3 жыл бұрын
the outputFeature variable contains the confidence of each class
@AshutoshKumar-yn6wf3 жыл бұрын
Hey bro can u tell me how to use full 1000 list of tensorflow in this code
@LAJianoran Жыл бұрын
it shuts off when I use my model
@nitesharu12693 жыл бұрын
can a pkl file be used in android studio
@saifchowdhury97283 жыл бұрын
how can I add labels.txt code in this apps?
@localbus70083 жыл бұрын
I can't understand the folders hierarchy..
@__dekana__ Жыл бұрын
You are the best!!!!
@safalghalegurung4253 жыл бұрын
hello sir im having trouble with model having multiple class can you make video on it as well?
@safalghalegurung4253 жыл бұрын
there seems to be a video but its in kotlin and i am working on java project.
@programming_hut3 жыл бұрын
are you looking for this ----> kzbin.info/www/bejne/bHbVk3mHl52EiZo
@safalghalegurung4253 жыл бұрын
@@programming_hut well yes it is but i want it in java and this tutorial is based in kotlin.
@arsalanahmed34883 жыл бұрын
Can we use a teachable machine file here? using this method?
@programming_hut3 жыл бұрын
as far as it is tflite it should work... I never tried but it should work
@arsalanahmed34883 жыл бұрын
@@programming_hut i trying to use it
@programming_hut3 жыл бұрын
@@arsalanahmed3488 so did you got any error
@arsalanahmed34883 жыл бұрын
@@programming_hut i don't test it yet if it will be successfully run i will inform you
@arsalanahmed34883 жыл бұрын
@@programming_hut it's working proper but please let me know it's showing the result in number i don't want to show in number
@saipadmasree20483 жыл бұрын
sir how can i create h5 file for my project?
@rhk19913 жыл бұрын
thank you kind sir, i really need this one.
@handhikayp3 жыл бұрын
Sir, your drive links seems that you already remove the project into trash, can you renew the link? thanks
@programming_hut3 жыл бұрын
I'll see
@tauseefrehman22 жыл бұрын
Is this work for every kind of ML model?
@seymatezcan40583 жыл бұрын
Hello thank you for this video I have a question: How can I create model.tflite file on Jupyter notebook?
@rushidesai28363 жыл бұрын
Use Tensorflow with Python
@programming_hut3 жыл бұрын
try this kzbin.info/www/bejne/fZaqnXqHbZWgkMk
@deveshreekadu40873 жыл бұрын
Plz upload TFLite file on github As it is not available on drive
@programming_hut3 жыл бұрын
I'll see if i still have it on my laptop
@sarasaleh67513 жыл бұрын
HI ,thank u for the this great video , but i can't upload my model it is bigger than 200 MB , is there is another way of upload or I should paste my model in assets .? thanks
@programming_hut3 жыл бұрын
you can use api methods btw what your model do
@sarasaleh67513 жыл бұрын
@@programming_hut thank u , I don’t know how to use api methods .. my model it to recognize images type .. from an image
@programming_hut3 жыл бұрын
may be this could help converting ml model to api : kzbin.info/www/bejne/bYXIaKWug5qeaMk how to make api android app : kzbin.info/www/bejne/n6GropyjbM2in9E
@fawniaavissa9711 Жыл бұрын
thankyou 8:35
@nishilraiyarela51412 жыл бұрын
Thanks it works
@robertgermia57583 жыл бұрын
I used my model with leaf images for prediction. It successfully worked when I use leaf image. But it also gives prediction results for any image ex:-pencil. Can you please tell me how to validate only to predict the leaf images? I hope you will reply. Thank you. i think it is in if probability score > threshold value but I didn't have idead how to do it.
@programming_hut3 жыл бұрын
when you trained your model you need add one more class called unknown and in that add whatever unknown images you can get . again train it and then try. I hope this could work.
@dwiencabalquinto55452 жыл бұрын
did you solve your problem?
@sivanit31503 жыл бұрын
The video is too excellent!!!! But I'm getting error while using start activity for result, it says it is deprecated... What should i do now... Any suggestions... Also I'm getting an error as when i click on predict button, the app closes... I'm bit confused as to what would cause this. Thanks for your suggestion in advance!!