Framework for simulating sociotechnical systems
Project description
A simulator for sociotechnical systems. More details coming soon.
Install
This simulator supports Python 3.7+ and it has not been tested with older versions of Python 3. If you have not configured a Python environment locally, please follow Scipy’s instructions for installing a scientific Python distribution.
If you do not have Python 3.7+ installed, you can create a new environment with Python 3.7 by running the following command in terminal:
conda create --name py37 python=3.7
To ensure the example Jupyter notebooks run in your Python 3.7 environment, follow the instructions from this blog post. Note: you will also need pandas to run the example notebooks. As of December 2020, we recommend installing pandas v1.0.5 using the command: pip install 'pandas==1.0.5'. This will help avoid package conflicts between pandas and pylint if you also plan on contributing to trecs and running tests.
Currently, the simulator has only been tested extensively on MacOS 10.15 and Ubuntu 20.04.
To install the simulator, you will need the Python package manager, pip. After activating your virtual environment, run the following commands in a terminal:
git clone https://github.com/elucherini/t-recs.git
cd t-recs
pip install -e .
The command should automatically install all dependencies.
Tutorials
Examples of how to use the simulator can be found in the notebooks below:
Quick start: start here for a brief introduction.
Complete guide: an overview of the main concepts of the system.
Advanced guide - building a model: an introduction to adding your own models on top of the system.
Advanced guide - adding metrics: an example of how to add new metrics to a model.
Please check the examples directory for more notebooks.
Example usage
import trecs
recsys = trecs.models.ContentFiltering()
recsys.run(timesteps=10)
measurements = recsys.get_measurements()
Documentation
A first draft of the documentation is available here. In its current version, the documentation can be used as a supplement to exploring details in the code. Currently, the tutorials in examples might be a more useful and centralized resource to learn how to use the system.
Contributing
Thanks for your interest in contributing! Check out the guidelines for contributors in CONTRIBUTING.md.
Project details
Release history Release notifications | RSS feed
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 trecs-0.1.0.tar.gz.
File metadata
- Download URL: trecs-0.1.0.tar.gz
- Upload date:
- Size: 46.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.7.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
762bf7792db3c57fab8c42c2347621b1378275a370cab482442dd8f639f3b956
|
|
| MD5 |
d21e621e606cfbff4eafbfb74f5f36c7
|
|
| BLAKE2b-256 |
2a65fb99fd4942e95d435311f86caa8aed778cf0a773061714168abdaf457827
|
File details
Details for the file trecs-0.1.0-py3-none-any.whl.
File metadata
- Download URL: trecs-0.1.0-py3-none-any.whl
- Upload date:
- Size: 12.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.7.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
16b7b4b19033e91853a28b9b6e3bd10a7ae648babb0af1d35e0fd6e98e5d6513
|
|
| MD5 |
7b6a7ab46560b9df6ff833d4076ab57b
|
|
| BLAKE2b-256 |
38cd0e7369fad9a5bd4b34aa8550c8e441761fcf50236ce42f21f90a70b50cd5
|