* Added Binary Focal Cross Entropy
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Fixed Issue
* Fixed Issue
* Added BFCE loss to loss_functions.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update machine_learning/loss_functions.py
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Tianyi Zheng <tianyizheng02@gmail.com>
* Add: FP Growth Algorithm
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* changes names
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Revert "changes names"
This reverts commit c0470094d0.
* refactore code
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update frequent_pattern_growth.py
---------
Co-authored-by: Jeel Gajera <jeelgajera00@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* Added Mean Squared Logarithmic Error (MSLE)
* Added Mean Squared Logarithmic Error (MSLE)
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Adds exponential moving average algorithm
* code clean up
* spell correction
* Modifies I/O types of function
* Replaces generator function
* Resolved mypy type error
* readibility of code and documentation
* Update exponential_moving_average.py
* Adds hinge loss function
* suggested doc and refactoring changes
* refactoring
---------
Co-authored-by: Christian Clauss <cclauss@me.com>
* feat: adding Apriori Algorithm
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: doctest, typo
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: type error, code refactore
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: refactore code
* fix: doctest
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: E501, B007
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: err
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: arg typ err
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fix: typo
* fix: typo
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Replace generate_candidates() with itertools.combinations()
* mypy
* Update apriori_algorithm.py
---------
Co-authored-by: Jeel Gajera <jeelgajera00@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* Replacing the generator with numpy vector operations from lu_decomposition.
* Revert "Replacing the generator with numpy vector operations from lu_decomposition."
This reverts commit ad217c6616.
* the change removes the warning:
/home/runner/work/Python/Python/machine_learning/k_means_clust.py:236: FutureWarning: The provided callable <function sum at 0x7f20c02034c0> is currently using SeriesGroupBy.sum. In a future version of pandas, the provided callable will be used directly. To keep current behavior pass the string "sum" instead.
.agg(
And
/home/runner/work/Python/Python/machine_learning/k_means_clust.py:236: FutureWarning: The provided callable <function mean at 0x7f3d7db1c5e0> is currently using SeriesGroupBy.mean. In a future version of pandas, the provided callable will be used directly. To keep current behavior pass the string "mean" instead.
.agg(
* DRAFT: GitHub Actions: Test on Python 3.12
Repeats #8777
* #8777
Some of our dependencies will not be ready yet.
* Python 3.12: Disable qiskit and tensorflow algorithms
* updating DIRECTORY.md
---------
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Fix DeprecationWarning in local_weighted_learning.py
Fix DeprecationWarning that occurs during build due to converting an
np.ndarray to a scalar implicitly
* DeprecationWarning fix attempt 2
* Add type hints to k_nearest_neighbours.py
* Refactor k_nearest_neighbours.py into class
* Add documentation to k_nearest_neighbours.py
* Use heap-based priority queue for k_nearest_neighbours.py
* Delete knn_sklearn.py
* updating DIRECTORY.md
* Use optional args in k_nearest_neighbours.py for demo purposes
* Fix wrong function arg in k_nearest_neighbours.py
---------
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Update xgboost_regressor.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Reimplement polynomial_regression.py
Rename machine_learning/polymonial_regression.py to
machine_learning/polynomial_regression.py
Reimplement machine_learning/polynomial_regression.py using numpy
because the old original implementation was just a how-to on doing
polynomial regression using sklearn
Add detailed function documentation, doctests, and algorithm
explanation
* updating DIRECTORY.md
* Fix matrix formatting in docstrings
* Try to fix failing doctest
* Debugging failing doctest
* Fix failing doctest attempt 2
* Remove unnecessary return value descriptions in docstrings
* Readd placeholder doctest for main function
* Fix typo in algorithm description
---------
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Solving the `Top k most frequent words` problem using a max-heap
* Mentioning Python standard library solution in `Top k most frequent words` docstring
* ruff --fix .
* updating DIRECTORY.md
---------
Co-authored-by: Amos Paribocci <aparibocci@gmail.com>
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Update rsa_cipher.py by replacing %s with {}
* Update rsa_cipher.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update linear_discriminant_analysis.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update linear_discriminant_analysis.py
* Update linear_discriminant_analysis.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update linear_discriminant_analysis.py
* Update linear_discriminant_analysis.py
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update linear_discriminant_analysis.py
* Update machine_learning/linear_discriminant_analysis.py
Co-authored-by: Christian Clauss <cclauss@me.com>
* Update linear_discriminant_analysis.py
* updated
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* pre-commit: Upgrade psf/black for stable style 2023
Updating https://github.com/psf/black ... updating 22.12.0 -> 23.1.0 for their `2023 stable style`.
* https://github.com/psf/black/blob/main/CHANGES.md#2310
> This is the first [psf/black] release of 2023, and following our stability policy, it comes with a number of improvements to our stable style…
Also, add https://github.com/tox-dev/pyproject-fmt and https://github.com/abravalheri/validate-pyproject to pre-commit.
I only modified `.pre-commit-config.yaml` and all other files were modified by pre-commit.ci and psf/black.
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
---------
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* updating DIRECTORY.md
* Format local_weighted_learning.py doctests for clarity
* Refactor local_weighted_learning.py to use np.array instead of np.mat
The np.matrix class is planned to be eventually depreciated in favor of
np.array, and current use of the class raises warnings in pytest
* Update local_weighted_learning.py documentation
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
* Add autoclave cipher
* Update autoclave with the given suggestions
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Fixing errors
* Another fixes
* Update and rename autoclave.py to autokey.py
* Rename gaussian_naive_bayes.py to gaussian_naive_bayes.py.broken.txt
* Rename gradient_boosting_regressor.py to gradient_boosting_regressor.py.broken.txt
* Rename random_forest_classifier.py to random_forest_classifier.py.broken.txt
* Rename random_forest_regressor.py to random_forest_regressor.py.broken.txt
* Rename equal_loudness_filter.py to equal_loudness_filter.py.broken.txt
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
* refactor: Move pascals triange to maths/
* Update xgboost_classifier.py
* statsmodels is now compatible with Python 3.11
* statsmodels is now compatible with Python 3.11
* cython>=0.29.28
* cython>=0.29.28 # For statsmodels on Python 3.11
Co-authored-by: Christian Clauss <cclauss@me.com>
* Added mean absolute error in linear regression
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Code feedback changes
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Apply suggestions from code review
Co-authored-by: Caeden Perelli-Harris <caedenperelliharris@gmail.com>
* Apply suggestions from code review
* Update linear_regression.py
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Christian Clauss <cclauss@me.com>
Co-authored-by: Caeden Perelli-Harris <caedenperelliharris@gmail.com>
* Added cosine similarity
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Adopt Python >= 3.8 assignment expressions using auto-walrus
* updating DIRECTORY.md
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
Co-authored-by: github-actions <${GITHUB_ACTOR}@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>