ml-template

Collections of code snippets for and beyond machine learning

https://github.com/itomxy/ml-template

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.3%) to scientific vocabulary

Keywords

computer-vision machine-learning
Last synced: 6 months ago · JSON representation ·

Repository

Collections of code snippets for and beyond machine learning

Basic Info
  • Host: GitHub
  • Owner: iTomxy
  • License: mit
  • Language: Python
  • Default Branch: master
  • Homepage:
  • Size: 481 KB
Statistics
  • Stars: 5
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Topics
computer-vision machine-learning
Created over 5 years ago · Last pushed 7 months ago
Metadata Files
Readme Citation

README.md

ml-template

My personal code snippet library of helper functions and classes, some with example.

  • +itom/: Tool functions that might be used in MATLAB codes. The leading + will add this folder into the searching path.

  • configurations/: Configuration files.

  • containers/: Definition files of Docker and Singularity image.

  • git/: git-related command showcases and .gitignore template.

  • latex/: LaTeX preamble template for academic papers and a rebuttal analysis Excel template.

  • losses/: Implementation of some deep learning loss functions.

  • scripts/: Utility scripts.

  • utils/: Utilities.

  • args.py: An example of using the argparse package in Python.

  • config.yaml: An example of writing arguments in YAML. Can be used together with utils/config.py.

  • requirements.txt: Common packages I met that a Docker image may not contain.

badge badge

Sometimes you may want to create a badge in your GitHub repository README. Use Shields.io to make one. See Static Badge for basic usage. In markdown, you make one by inserting a: md ![SOME_ALTERNATIVE_TEXT](https://img.shields.io/badge/:badgeContent) where :badgeContent has to be replaced by some fields. For example, a badge of this repository can be iTomxy/ml-template: md ![iTomxy/ml-template](https://img.shields.io/badge/iTomxy-ml--template-blue?logo=github) where: - iTomxy-ml--template-blue is a --separated string, containing 3 fields: 1) left part text, 2) right part text, and 3) right part background colour. - logo specifies the logo shown in the left part. The logo name should be from Simple Icons.

If you also want to add a hyperlink on the badge instead of letting it be a pure icon, you just wrap it with [badge-code](link) iTomxy/ml-template: md [![iTomxy/ml-template](https://img.shields.io/badge/iTomxy-ml--template-blue?logo=github)](https://github.com/iTomxy/ml-template) Althoug the Shilds.io badge supports inserting link by itself (see Static Badge), but it seems that this is not usable in GitHub (see How to specify the link of left and right on GitHub #5593).

hosts

some entries to be added in hosts file for GitHub accessing:

140.82.114.4 github.com 199.232.5.194 github.global.ssl.fastly.net 199.232.68.133 raw.githubusercontent.com

see [9] for automatic hosts updating.

pip

change the source of pip, see [7, 8].

While you can add the configuration file yourself, a quicker way would be using one of the following commands:

```shell

Tsinghua

pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple

Alibaba

pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/

Tencent

pip config set global.index-url http://mirrors.cloud.tencent.com/pypi/simple

Douban

pip config set global.index-url http://pypi.douban.com/simple/ ```

References

  1. AlexNet implementation + weights in TensorFlow
  2. mikechen66/AlexNet_TensorFlow2.0-2.2
  3. Finding source of NaN in forward pass
  4. torch.autograd.detect_anomaly
  5. deep-cross-modal-hashing/torchcmh/dataset/base/triplet.py
  6. 【BUG】[nltk_data] Error loading punkt: <urlopen error [Errno 11004] [nltk_data]
  7. Python 修改 pip 源为国内源
  8. python - pip换源,更换pip源到国内镜像
  9. 521xueweihan/GitHub520
  10. 解决pip安装超时的问题
  11. screen
  12. 亲测!screen好看好用的配置(Linux)
  13. How can I run Tensorboard on a remote server?

Owner

  • Name: iTom
  • Login: iTomxy
  • Kind: user
  • Company: The Chinese University of Hong Kong (Shenzhen)

tom.tyliang@gmail.com hackeritom@163.com

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it using these metadata."
authors:
- family-names: "Liang"
  given-names: "Tianyou"
  orcid: "https://orcid.org/0000-0002-2213-3029"
title: "ml-template"
version: 2025.5.8
date-released: 2025-05-08
url: "https://github.com/iTomxy/ml-template"
license: "MIT"

GitHub Events

Total
  • Push event: 30
Last Year
  • Push event: 30

Dependencies

requirements.txt pypi
  • Cython *
  • Pillow *
  • PyYAML *
  • albumentations *
  • easydict *
  • fire *
  • graphviz *
  • h5py *
  • matplotlib *
  • nltk *
  • numpy *
  • opencv-python-headless *
  • pandas *
  • pickleshare *
  • scikit-learn *
  • scipy *
  • tensorboard *
  • tqdm *
  • xlwt *