regresspy
is a python module for carrying out simple regressions using gradient descent algorithm. However, the library is half complete. Your task is to fill in the necessary codes. The tasks of the project is given below:
- Fork this repository.
- Create a new branch using your username.
- Fill in the
.gitignore
file by creating one for Python from .gitignore.io. - Commit frequently, usually everytime after changing or completing a function. Make the commit messages clear and complete. You may read this blog to learn about writing good commit messages.
- Write the codes for the mean absolute, sum of squared, mean squared, and root mean squared errors in the
loss.py
file. - Complete the
test_loss.py
by filling in the codes to test above functions. An example for testingmae
is already given. You may read this blog or any other to learn aboutpytest
. - After that, go to the
gradient_descent.py
file. It contains two functions namedforward
for computing forward propagation andbackward
for computing the gradients. The second one is already done for you. All you have to do is fill in the codes for forward propagation. - Then go to the
main.py
file where the actual training will take place. The first task is to complete the_initialize_weights
function. Then complete the_train
function. Finally, complete thepredict
andscore
function. - Now, go the
model.py
file in thetest
folder. Here, you will perform two regressions. First one will be carried out using theSGDRegressor
from thesklearn
library. Second one will be carried out using your own codes. Compare the results and write in theREADME.md
file (You can delete this README file). - Fill in the
requirements.txt
file according to the libraries you have used in your codes. - Fill-in the
setup.py
file to install your code as a library. You may read this blog or the Python documentation to learn how to prepare this file. - Give an appropriate license to your library in the
LICENSE
file. You may use choosealicense.com to select the best one according to your case. - Try to make your code look beautiful. You can add optional documentation about how to use your library in the
README
file. Look for other repositories and see how they have documented. - Finally, email me the link of your repository.