Skip to content

Commit

Permalink
move laboratory
Browse files Browse the repository at this point in the history
  • Loading branch information
quillcraftsman committed Oct 25, 2023
1 parent 578d796 commit 47e5e2d
Show file tree
Hide file tree
Showing 68 changed files with 3,136 additions and 518 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# .github/workflows/run-tests.yml
name: Run tests

on:
push:

jobs:
tests:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run tests
run: |
make coverage
161 changes: 160 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,160 @@
.idea
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/#use-with-ide
.pdm.toml

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
.idea/
36 changes: 18 additions & 18 deletions CHECKLIST.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
[Main points](https://github.com/quillcraftsman/open-source-checklist#main-points)
- [x] [Open Source Project Checklist](https://github.com/quillcraftsman/open-source-checklist#open-source-project-checklist)
- [ ] [Existing Analogues](https://github.com/quillcraftsman/open-source-checklist#existing-analogues)
- [ ] [Good Project Name](https://github.com/quillcraftsman/open-source-checklist#good-project-name)
- [x] [Existing Analogues](https://github.com/quillcraftsman/open-source-checklist#existing-analogues)
- [x] [Good Project Name](https://github.com/quillcraftsman/open-source-checklist#good-project-name)
- [ ] [Mission](https://github.com/quillcraftsman/open-source-checklist#mission)
- [ ] [State What the Project Is Free](https://github.com/quillcraftsman/open-source-checklist#state-what-the-project-is-free)
- [ ] [Features](https://github.com/quillcraftsman/open-source-checklist#features)
- [ ] [Requirements](https://github.com/quillcraftsman/open-source-checklist#requirements)
- [ ] [Development Status](https://github.com/quillcraftsman/open-source-checklist#development-status)
- [ ] [Download Page](https://github.com/quillcraftsman/open-source-checklist#download-page)
- [ ] [Version Control Access](https://github.com/quillcraftsman/open-source-checklist#version-control-access)
- [ ] [Bug Tracker Access](https://github.com/quillcraftsman/open-source-checklist#bug-tracker-access)
- [ ] [Communication Channels](https://github.com/quillcraftsman/open-source-checklist#communication-channels)
- - [ ] Discussions
- [x] [Version Control Access](https://github.com/quillcraftsman/open-source-checklist#version-control-access)
- [x] [Bug Tracker Access](https://github.com/quillcraftsman/open-source-checklist#bug-tracker-access)
- [x] [Communication Channels](https://github.com/quillcraftsman/open-source-checklist#communication-channels)
- - [x] Discussions
- - [ ] Mailing List
- - [ ] Real-time chat
- - [ ] Forum
- [ ] [Developer Guidelines](https://github.com/quillcraftsman/open-source-checklist#developer-guidelines)
- [ ] [Documentation](https://github.com/quillcraftsman/open-source-checklist#documentation)
- [ ] [Developer Documentation](https://github.com/quillcraftsman/open-source-checklist#developer-documentation)
- [ ] [Availability of Documentation](https://github.com/quillcraftsman/open-source-checklist#availability-of-documentation)
- [ ] [FAQ](https://github.com/quillcraftsman/open-source-checklist#faq)
- [ ] [Examples Output and Screenshots](https://github.com/quillcraftsman/open-source-checklist#examples-output-and-screenshots)
- [ ] [License](https://github.com/quillcraftsman/open-source-checklist#license)
- [ ] [Code of Conduct](https://github.com/quillcraftsman/open-source-checklist#code-of-conduct)
- [ ] [Security Policy](https://github.com/quillcraftsman/open-source-checklist#security-policy)
- [ ] [Governance](https://github.com/quillcraftsman/open-source-checklist#governance)
- [ ] [Issue templates](https://github.com/quillcraftsman/open-source-checklist#issue-templates)
- [ ] [Support](https://github.com/quillcraftsman/open-source-checklist#support)
- [x] [Developer Guidelines](https://github.com/quillcraftsman/open-source-checklist#developer-guidelines)
- [x] [Documentation](https://github.com/quillcraftsman/open-source-checklist#documentation)
- [x] [Developer Documentation](https://github.com/quillcraftsman/open-source-checklist#developer-documentation)
- [x] [Availability of Documentation](https://github.com/quillcraftsman/open-source-checklist#availability-of-documentation)
- [x] [FAQ](https://github.com/quillcraftsman/open-source-checklist#faq)
- [x] [Examples Output and Screenshots](https://github.com/quillcraftsman/open-source-checklist#examples-output-and-screenshots)
- [x] [License](https://github.com/quillcraftsman/open-source-checklist#license)
- [x] [Code of Conduct](https://github.com/quillcraftsman/open-source-checklist#code-of-conduct)
- [x] [Security Policy](https://github.com/quillcraftsman/open-source-checklist#security-policy)
- [x] [Governance](https://github.com/quillcraftsman/open-source-checklist#governance)
- [x] [Issue templates](https://github.com/quillcraftsman/open-source-checklist#issue-templates)
- [x] [Support](https://github.com/quillcraftsman/open-source-checklist#support)

[CI and CD](https://github.com/quillcraftsman/open-source-checklist#ci-and-cd)
- [ ] Tests
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,5 @@ Additionally, the code should follow any stylistic and architectural guidelines
prescribed by the project. In the absence of such guidelines, mimic the styles
and patterns in the existing code-base.

[issues-path]: https://github.com/quillcraftsman/open-source-checklist/issues
[discussions-path]: https://github.com/quillcraftsman/open-source-checklist/discussions
[issues-path]: https://github.com/findsimilar/laboratory/issues
[discussions-path]: https://github.com/findsimilar/laboratory/discussions
26 changes: 26 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
make test:
python manage.py test

test-proximity:
python manage.py test analysis.tests.tests_proximity

server:
python manage.py runserver

coverage:
coverage run --source='.' manage.py test
coverage html --omit=laboratory/asgi.py,laboratory/wsgi.py,manage.py,analysis/management/*
coverage report --omit=laboratory/asgi.py,laboratory/wsgi.py,manage.py,analysis/management/* --fail-under=100


migrate:
python manage.py migrate

compare_two:
python manage.py compare_two "$(one)" "$(two)"

example_frequency_analysis:
python manage.py example_frequency_analysis "$(example)"

load_training_data:
python manage.py load_training_data $(name) $(filepath) $(sheet_name)
Loading

0 comments on commit 47e5e2d

Please sign in to comment.