Machine Learning Model Deployment Flask and Test API using Postman
Machine Learning Model Deployment Flask and Test API using Postman
GitHub JupyterNotebook: github.com/siddiquiamir/ML-Mo...
GitHub Data: github.com/siddiquiamir/Data
About this video: In this video, you will learn how to test your flask API using Postman
Large Language Model (LLM) - LangChain
LangChain: • LangChain Tutorial for...
Large Language Model (LLM) - LlamaIndex
LlamaIndex: • LlamaIndex Tutorial fo...
Machine Learning Model Deployment
ML Model Deployment: • ML Model Deployment us...
Spark with Python (PySpark)
PySpark: https: • PySpark with Python
Data Preprocessing (scikit-learn)
Data Preprocessing Python: • Data Preprocessing Python
Social Media Links
KZread: / statswire
Twitter (X) : / statswire
#llm #ai #genai #generativeai #statswire #pyspark #python #pythonprogramming #pythontutorial #machinelearning #datascience #naturallanguageprocessing #nlp #nltk
#MachineLearning #Flask #Postman
Пікірлер: 44
Please watch the video in full screen because the font size is a little small also download the entire code from GitHub, the link is provided in the description so you can increase the font size and change the theme if you want in your local machine. Thank you for watching. Here is the code link: github.com/siddiquiamir/ML-Model-Deployment-And-Test-Using-Postman
@dimannish1
Жыл бұрын
my friend. the content of app.py in Github and that APP.PY your had shown in video is not the same. I retyped version from video and got working version. Please consider
@StatsWire
Жыл бұрын
@@dimannish1 Thank you for informing. I will check.
Amazing tutorial! Worked perfectly thanks!
@StatsWire
8 ай бұрын
You're welcome!
Great way of teaching👍
@StatsWire
3 жыл бұрын
Thank you
Thanks for helping. Really informative video
@StatsWire
Жыл бұрын
You're welcome
That's one helpful video. Thanks
@StatsWire
2 жыл бұрын
You're welcome
Very nice tutorial
@StatsWire
3 жыл бұрын
Thank you
Nice tutorial 👌👌
@StatsWire
2 жыл бұрын
Thank you
Thanks for the Video ! One doubt how are we using predicted output variable y=df["Class"] directly and not converting it into numerical values (like-0,1,2) for prediction?
@StatsWire
Жыл бұрын
We are just testing here that is why
The model I need to use was yolov5 coustom model so how to import that model into this sir.
What if i have categorical features in my model? Sure I would encode them but what changes should be made in the production code so that it accepts strings as an entry
@StatsWire
3 жыл бұрын
You have to make the same changes in the production that you will make in your script. Nothing extra is required. It will work fine.
Nice video sir. How to implement the same if the values are of type string as well as the output return from the model is of type string?
@StatsWire
2 жыл бұрын
Yes, there is a way for the string as well. I
@shivaninaeck2524
2 жыл бұрын
@@StatsWire can you explain how sir?
thanks, sir for making such an informative video, you have helped me with my project a lot, as I have followed up with your tutorial, it works fine, but once I deploy it on AWS , when I called "/predict" it doesn't work, I have already updated the directory on ubuntu, but Nah, it doesn't work it still Internal Server Error. The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application. Please help me out with that. Looking forward to hearing back from you. Thanks
@StatsWire
2 жыл бұрын
Hello, sorry for the late response.
Hello, I followed your instructions and tried this in Pycharm community version. However, when I run the script, I don't see any URL link to local host and there is no error either. Is the URL thingy not available in community version?
@StatsWire
Жыл бұрын
I am also using the community version and everyone uses the same because it's free. I would suggest you to please follow each and every step again. You may have missed something.
will this work for an image classification model also ?
@StatsWire
17 сағат бұрын
I have not tried it on the image dataset
Can one use image and audio data?
@StatsWire
Ай бұрын
I have not tried it yet
can you share the repository sir?
@StatsWire
2 жыл бұрын
Please find the link to the Github repository github.com/siddiquiamir/ML-Model-Deployment-And-Test-Using-Postman/tree/main/ML%20Model%20Deployment%20And%20Test%20Using%20Postman
pass categorical variable dude....only you pass inte values
model.pkl from where ?
@StatsWire
3 жыл бұрын
It is your machine learning model that you convert to pkl in the last line of the file "model.py"
@hamonangansitorus5761
3 жыл бұрын
@@StatsWire thankyou so much
@StatsWire
3 жыл бұрын
@@hamonangansitorus5761 You're welcome
Hi, help me please, do I need to write PIN that I got after running "app.py" somewhere in Postman ? Because now when I click SEND I got error "405 Method Not Allowed. The method is not allowed for the requested URL."
@StatsWire
Жыл бұрын
See you are in the same one
@dimannish1
Жыл бұрын
UPD: to get rid of this error please use @flask_app.route('/predict', methods=['GET', 'POST']) instead of @flask_app.route('/predict', methods=['POST'])
@StatsWire
Жыл бұрын
@@dimannish1 Thank you for writing the methods!
@dimannish1
Жыл бұрын
@@StatsWire script goes further, but not till the end. Now he's complaining for that error "ValueError: Found array with 0 feature(s) (shape=(1, 0)) while a minimum of 1 is required by RandomForestClassifier". Need something more to succeed
@cmaly6167
Жыл бұрын
@@dimannish1 Here is the code that worked for me. Replace the existing "def predict()" with this. def predict(): json_data = request.get_json() features = [] for record in json_data: float_features = [float(record['Sepal_Length']), float(record['Sepal_Width']), float(record['Petal_Length']), float(record['Petal_Width'])] features.append(float_features) predictions = model.predict(features) return jsonify({'predictions': predictions.tolist()})