跳转到主要内容

数据科学项目PyScaffold扩展

项目描述

Build Status ReadTheDocs Coveralls PyPI-Server Conda-Forge Downloads

pyscaffoldext-dsproject

PyScaffold 为数据科学项目定制的扩展。此扩展受到 cookiecutter-data-science 的启发,并在许多方面得到了增强。主要区别在于它

  1. 提倡一种合适的Python包结构,以便进行分发和传输,
  2. 使用conda环境代替基于virtualenv的解决方案,因此更适合数据科学项目,
  3. Sphinxpytestpre-commit等提供更多默认配置,以促进干净编码和最佳实践。

还可以考虑使用dvc来版本控制和共享团队内部的数据。阅读这篇博客文章,了解如何通过使用类似这种的数据科学项目结构来有效地使用JupyterLab笔记本。

最终的目录结构如下所示

├── AUTHORS.md              <- List of developers and maintainers.
├── CHANGELOG.md            <- Changelog to keep track of new features and fixes.
├── CONTRIBUTING.md         <- Guidelines for contributing to this project.
├── Dockerfile              <- Build a docker container with `docker build .`.
├── LICENSE.txt             <- License as chosen on the command-line.
├── README.md               <- The top-level README for developers.
├── configs                 <- Directory for configurations of model & application.
├── data
│   ├── external            <- Data from third party sources.
│   ├── interim             <- Intermediate data that has been transformed.
│   ├── processed           <- The final, canonical data sets for modeling.
│   └── raw                 <- The original, immutable data dump.
├── docs                    <- Directory for Sphinx documentation in rst or md.
├── environment.yml         <- The conda environment file for reproducibility.
├── models                  <- Trained and serialized models, model predictions,
│                              or model summaries.
├── notebooks               <- Jupyter notebooks. Naming convention is a number (for
│                              ordering), the creator's initials and a description,
│                              e.g. `1.0-fw-initial-data-exploration`.
├── pyproject.toml          <- Build configuration. Don't change! Use `pip install -e .`
│                              to install for development or to build `tox -e build`.
├── references              <- Data dictionaries, manuals, and all other materials.
├── reports                 <- Generated analysis as HTML, PDF, LaTeX, etc.
│   └── figures             <- Generated plots and figures for reports.
├── scripts                 <- Analysis and production scripts which import the
│                              actual PYTHON_PKG, e.g. train_model.
├── setup.cfg               <- Declarative configuration of your project.
├── setup.py                <- [DEPRECATED] Use `python setup.py develop` to install for
│                              development or `python setup.py bdist_wheel` to build.
├── src
│   └── PYTHON_PKG          <- Actual Python package where the main functionality goes.
├── tests                   <- Unit tests which can be run with `pytest`.
├── .coveragerc             <- Configuration for coverage reports of unit tests.
├── .isort.cfg              <- Configuration for git hook that sorts imports.
└── .pre-commit-config.yaml <- Configuration of pre-commit git hooks.

dsproject-demo下查看初始项目结构的演示,并查看PyScaffold的文档以获取更多信息。

使用方法

只需使用conda install -c conda-forge pyscaffoldext-dsproject安装此软件包,注意putup -h显示了新的选项--dsproject。创建数据科学项目就像这样一样简单

putup --dsproject my_ds_project

--dsproject标志还包含--markdown--pre-commit--no-skeleton等标志,以便于使用。

修改和贡献

此项目使用pre-commit,请确保在做出任何更改之前安装它

conda install pre-commit
cd pyscaffoldext-dsproject
pre-commit install

更新钩子到最新版本是个好主意

pre-commit autoupdate

请参阅PyScaffold的贡献指南

项目详情


下载文件

下载适合您平台的文件。如果您不确定要选择哪个,请了解更多关于安装包的信息。

源代码分发

pyscaffoldext-dsproject-0.7.2.tar.gz (28.8 kB 查看散列)

上传时间 源代码

构建分发

pyscaffoldext_dsproject-0.7.2-py2.py3-none-any.whl (15.1 kB 查看散列)

上传时间 Python 2 Python 3

由以下支持

AWSAWS云计算和安全赞助商DatadogDatadog监控FastlyFastlyCDNGoogleGoogle下载分析MicrosoftMicrosoftPSF赞助商PingdomPingdom监控SentrySentry错误日志StatusPageStatusPage状态页面