A Django-based database for trials and events in the decide operant control system
Project description
Decide is an event-driven state-machine framework for running behavioral experiments with embeddable computers like the Beaglebone Black. This repository is a Django app that collates event and trial data from multiple devices running decide (version 3.0 or later) or decide-rs. It replaces decide-host, which was a bit snazzier but becoming difficult to maintain.
This should more or less be working but should be considered beta. You should continue to save trial information locally.
This software is licensed for you to use under the Gnu Public License, version 3. See COPYING for details
Quick start
Install the package from source: python setup.py install. Worth putting in a virtualenv.
Add decide_host to your INSTALLED_APPS setting like this:
INSTALLED_APPS = (
...
'rest_framework',
'django_filters',
'decide_host',
)
Include the decide_host URLconf in your project urls.py like this:
url(r'^decide/', include(decide_host.urls')),
Run python manage.py migrate to create the database tables.
Start the development server and point your browser to http://127.0.0.1:8000/decide/api/ to view records and inspect the API.
Importing trial data
If you have trial data in jsonl files that you’d like you import into the database, you can do this very easily. From your project site, run manage.py import_trials -n <name> -a <addr> trials.jsonl. You need to supply the name of the controller (addr) and the procedure (name). The import will not happen if there’s a duplicate in the database, so no need to worry about this.
Combining duplicate subjects
Subject names are set with user input, so there may be multiple records in the database that correspond to the same subject. To combine these records, run manage.py merge_subjects <to_keep> <to_combine>. Multiple names can be give for <to_combine>. It’s easy to mess the database up badly doing this so be sure to take a snapshot!
Development
Recommend using uv for development.
Run uv sync to create a virtual environment and install dependencies. uv sync --no-dev --frozen for deployment.
Testing: uv run pytest. Requires a test database, will use settings from inventory/test/settings.py.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_decide_host-0.3.11.tar.gz.
File metadata
- Download URL: django_decide_host-0.3.11.tar.gz
- Upload date:
- Size: 9.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
51b39e24528618ebdff84df947697f836d79f7c143e9b2727dde07406815b843
|
|
| MD5 |
743e72a1393d5a52f578a65aab208db2
|
|
| BLAKE2b-256 |
8a604bad3792204e053d768762a5c62716cd7f4616111e6c0b70e5603ba81b40
|
Provenance
The following attestation bundles were made for django_decide_host-0.3.11.tar.gz:
Publisher:
publish-to-pypi.yml on melizalab/django-decide-host
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
django_decide_host-0.3.11.tar.gz -
Subject digest:
51b39e24528618ebdff84df947697f836d79f7c143e9b2727dde07406815b843 - Sigstore transparency entry: 637670691
- Sigstore integration time:
-
Permalink:
melizalab/django-decide-host@97d217f291cc305011aebd830b04540baa1c3207 -
Branch / Tag:
refs/tags/v0.3.11 - Owner: https://github.com/melizalab
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@97d217f291cc305011aebd830b04540baa1c3207 -
Trigger Event:
push
-
Statement type:
File details
Details for the file django_decide_host-0.3.11-py3-none-any.whl.
File metadata
- Download URL: django_decide_host-0.3.11-py3-none-any.whl
- Upload date:
- Size: 14.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
288f5fa7959e763dc46f02b40a27f81122105f1f673004f7d4340b033415b254
|
|
| MD5 |
ab286591675ce942138f129115688eb3
|
|
| BLAKE2b-256 |
1a70e607f8947f6103fed783a5d6d16a4c65b7887dfe88643706aa9f947e2437
|
Provenance
The following attestation bundles were made for django_decide_host-0.3.11-py3-none-any.whl:
Publisher:
publish-to-pypi.yml on melizalab/django-decide-host
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
django_decide_host-0.3.11-py3-none-any.whl -
Subject digest:
288f5fa7959e763dc46f02b40a27f81122105f1f673004f7d4340b033415b254 - Sigstore transparency entry: 637670696
- Sigstore integration time:
-
Permalink:
melizalab/django-decide-host@97d217f291cc305011aebd830b04540baa1c3207 -
Branch / Tag:
refs/tags/v0.3.11 - Owner: https://github.com/melizalab
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@97d217f291cc305011aebd830b04540baa1c3207 -
Trigger Event:
push
-
Statement type: