Package: gms
Chart 1: Basic GMS WorkflowЭтот README.md на русском языке❤️Brief DescriptionGeneral Model Selection Module(next: GMS-Module)is a simple yet neat model selection tool that would help machine learning developers to get their hands on the most efficient model/pipeline for their specific task.This
project has brought me 5 points additionally for IT General State Exam (ЕГЭ по информатике)😌User only needs to pass:Models AND/OR Pipelinesof their choiceMetricsFor evaluationPivotif certain metric is more important than the othersDatato train and evaluate onModule would automatically make evaluations, store them and give verbose description of each model's performance!InstallationTo install GMSModule ensure that python3 and pip are installed. In terminal simply type:pip install gmsORpip3 install gmspip3installgmsHow to use?Make sure that all the variables are prepared to be used by GMS:mode: A string of your ML task:'regression' OR 'classification'include: A list of model-obj. of your choice:[LinearRegression(), SVR()]metrics: A list of strings to evaluate on:classification = ['accuracy', 'f1-score', 'precision', 'recall', 'roc-auc']regression = ['mae', 'mape', 'mse', 'rmse', 'r2-score']data: A list of your data to train/validate on:[X_train, X_test, y_train, y_test]pivot:if necessary: A string of one of metrics provided:'accuracy'(pivot is a metric that is most important for evaluation)Import GMSModule into your project:fromgms.GMSModuleimportGMSModuleCreate aGMSModuleobject with your data:GMSPipe=GMSModule(mode="classification",pivot='f1-score',metrics=['accuracy','f1-score'],include=[LogisticRegression(),RandomForestClassifier()],data=[X_train,X_test,y_train,y_test])Use any of methods provided:best_model,_=GMSPipe.best_model()print(best_model)RandomForestClassifier()Why this module?Every Machine Learning developer, especially after extensive data analysis, has to pickthe most precise Machine Learning model. Some engineers already know which model would fit perfectly, due to the ease of task given or due to the fact that ML model is evident.But some engineers might struggle with the BLIND choice between dozens if not HUNDREDS of ML models / pipelines that they have built. That's where GMS Module could help!User doesn't have to build a custom function that would evaluate each model one by one on their metrics.User just has to pass in each model and name metrics of their choiceandvoila!Then, user is able to look at theGMSModule.description()and get verbose information about models' evaluations and see which models are better than the others.Users can also get their data into variables for further usage, like in this example:# Get predictions of the best model from list_,preds=GMSModule.best_model()# DataFrame datadata={'id':range(25000),'value':preds}# Create a DataFrame and pass information into itdf=pd.DataFrame(data)df.to_csv('submit.csv',index=False)Project HistoryThis project was created as afun side project for meto experiment with scikit-learn tools. Project has helped me to become more focused on programming overall and taught me how to write my own PYPI module for others to use!The idea was born on16.10.2023and the first draft of the project was so inefficient, so that I had to rewrite almost everythingModule used to re-evaluate each time I've tried to get evaluations of each model. Evaluations used 'if-statements' which looked hideous and unprofessional.With the 5-th version done on20.10.2023everything has been changed. Re-evaluation problem was fixed, module could catch the most obvious exceptions caused by user and 'if-statements' were replaced with neat dictionaries.As if22.10.2023, I am creating the first version of this Markdown (README.md) file. Project is polished. All I need is to:Create a module file (*.py)Write a bunch of documentation: this doc in Russian, code run-through, basic use-cases and much more!Get a licensePost this module on PYPI21:54. 22.10.2023I've already posted my project to PYPI. Everything seems to work fine.23:28. 07.11.2023I've created a new 0.3.0 version that fixed some bugs I've encountered. Now module has less bugs. New feature added:GMSModule.to_df():)11:02. 09.11.2023New version 0.4.0. Now, you get get predictions of each model provided! Most of the comments were cleared due to the fact that they were
unnecessary.Quick MessageI WON'T UPDATE FILES FOR PYPI FOR THIS REPObecause those commits are:UnnecessaryBreak auto merge for gitSo please, don't look at files that are not related to gms-module code itself!TO DO:Create a Markdown file for Usage description and examplesFixed:Fixed issue withpivot = NoneerrorFixed issue with non-binary classification supportAdded:GMSModule.get_predictions()function. Now you can evaluate each model provided!My SocialsFull Name:  Nikita Zhamkov (Dmitrievich)Country, city:  Russia, Saint-PetersburgPhone number: +79119109210Email:nikitazhamkov@gmail.comGitHub:https://github.com/plugg1NTelegram:https://t.me/jeberkarawita