Skip to content

Jacobbishopxy/studies-ml

Repository files navigation

Studies ML

Installation

  1. Visit https://pytorch.org/ and select a suitable libtorch version to download.

    For example:

    # If you need e.g. CUDA 9.0 support, please replace "cpu" with "cu90" in the URL below.
    wget https://download.pytorch.org/libtorch/nightly/cpu/libtorch-shared-with-deps-latest.zip
    unzip libtorch-shared-with-deps-latest.zip
  2. Place the unzipped libtorch folder under the root of the project directory,and pick either one below

    # list(APPEND CMAKE_PREFIX_PATH "libtorch")
    list(APPEND Torch_DIR, "libtorch")

    ahead of find_package(Torch REQUIRED) in CMakeLists.txt.

Note: For Mac M1 user, besides following the steps above, we'll have several extra steps to be done. Check this.

Contents

Note: most of the comments and .tex files are written in Chinese [ch-CN].

Notes

  1. Studies of the Watermelon Book: Main entry & PDF

  2. Studies of Essential Math for AI: Main entry & PDF.

    • Data

    • Singular value decomposition

Codes

  1. Starter

  2. Basics

    • basics: cpp & py

    • linear regression: cpp & py

    • logistic regression: cpp & py

    • feed forward neural net: cpp & py

  3. Intermediate

    • convolutional neural network: cpp & py

    • deep residual network: cpp & py

  4. Advanced

  5. Interactive

Project Structure

CMake deps

  • extern

  • utils

References

  1. WatermelonBook [ch-CN]: https://cs.nju.edu.cn/zhouzh/zhouzh.files/publication/MLbook2016.htm

  2. PumpkinBook [ch-CN]: https://github.com/datawhalechina/pumpkin-book

  3. Essential Math for AI [en-US]: https://www.oreilly.com/library/view/essential-math-for/9781098107628/

  4. PyTorch: https://pytorch.org/

  5. PyTorch Cpp and PyTorch Py