Skip to content

Commit ec74b4e

Browse files
authored
Merge pull request #74 from argosp/fix-install-guide
Update Installation guide with Make workflow and correct versions
2 parents def8caf + b5701ea commit ec74b4e

1 file changed

Lines changed: 98 additions & 33 deletions

File tree

docs/user_guide/installation.md

Lines changed: 98 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -2,86 +2,151 @@
22

33
## Prerequisites
44

5-
- Python 3.7+
6-
- [Anaconda](https://www.anaconda.com/) (recommended)
5+
- Python 3.9+
6+
- [Anaconda](https://www.anaconda.com/) or any Python virtual environment manager
77

8-
## Installation
9-
10-
### 1. Create a virtual environment
8+
## Quick Install (with Make)
119

1210
```bash
13-
conda create -n Argos python=3.7
14-
conda activate Argos
11+
git clone git@github.com:argosp/pyargos.git
12+
cd pyargos
13+
make install
1514
```
1615

17-
### 2. Install dependencies
16+
This will:
17+
18+
1. Install all Python dependencies from `requirements.txt`
19+
2. Prompt to add `PYTHONPATH` to your `~/.bashrc` (or `~/.zshrc` for zsh users)
20+
21+
After installation, open a new terminal or run `source ~/.bashrc` to activate.
22+
23+
## Manual Install
24+
25+
### 1. Clone the repository
1826

1927
```bash
20-
pip install paho-mqtt numpy pandas urllib3 requests
28+
git clone git@github.com:argosp/pyargos.git
29+
cd pyargos
2130
```
2231

23-
### 3. Optional dependencies
32+
### 2. Create a virtual environment
2433

25-
Depending on your use case, install additional packages:
34+
=== "Conda"
2635

27-
=== "ThingsBoard"
36+
```bash
37+
conda create -n Argos python=3.11
38+
conda activate Argos
39+
```
40+
41+
=== "venv"
2842

2943
```bash
30-
pip install tb_rest_client
44+
python3 -m venv .venv
45+
source .venv/bin/activate
3146
```
3247

48+
### 3. Install dependencies
49+
50+
```bash
51+
pip install -r requirements.txt
52+
```
53+
54+
### 4. Add pyargos to your PYTHONPATH
55+
56+
```bash
57+
export PYTHONPATH="/path/to/pyargos:$PYTHONPATH"
58+
```
59+
60+
To make this permanent, use the Makefile helper:
61+
62+
```bash
63+
make env-persist
64+
```
65+
66+
This will prompt to add the export line to your `~/.bashrc` or `~/.zshrc`.
67+
68+
Alternatively, add it manually:
69+
70+
```bash
71+
echo 'export PYTHONPATH="/path/to/pyargos:$PYTHONPATH" # pyArgos' >> ~/.bashrc
72+
```
73+
74+
### 5. Verify the installation
75+
76+
```bash
77+
python -c "import argos; print(argos.__version__)"
78+
```
79+
80+
This should print the current version (e.g., `1.2.3`).
81+
82+
## Optional Dependencies
83+
84+
pyArgos works with several external systems. Install only what you need:
85+
3386
=== "Kafka"
3487

3588
```bash
3689
pip install kafka-python
3790
```
91+
Required for: Kafka topic creation and data consumption.
3892

39-
=== "NoSQL (Cassandra)"
93+
=== "ThingsBoard"
94+
95+
```bash
96+
pip install tb_rest_client
97+
```
98+
Required for: Device management and trial deployment via ThingsBoard REST API.
99+
100+
=== "Cassandra"
40101

41102
```bash
42103
pip install cassandra-driver dask
43104
```
105+
Required for: Querying ThingsBoard's Cassandra telemetry backend.
44106

45-
=== "NoSQL (MongoDB)"
107+
=== "MongoDB"
46108

47109
```bash
48110
pip install pymongo dask
49111
```
112+
Required for: Querying MongoDB time-series collections.
50113

51114
=== "Node-RED Parquet nodes"
52115

53116
```bash
54117
pip install dask fastparquet
55118
```
119+
Required for: The `to_parquet` custom Node-RED node.
56120

57-
### 4. Add pyargos to your PYTHONPATH
58-
59-
```bash
60-
export PYTHONPATH=$PYTHONPATH:/path/to/pyargos
61-
```
121+
=== "All optional"
62122

63-
!!! tip
64-
Add this line to your `~/.bashrc` or `~/.zshrc` to make it permanent.
123+
```bash
124+
make install-dev
125+
```
126+
Installs Kafka, ThingsBoard, and documentation dependencies.
65127

66-
### 5. Activate the environment
128+
## Make Targets Reference
67129

68-
```bash
69-
conda activate Argos
70-
```
130+
| Target | Description |
131+
|--------|-------------|
132+
| `make install` | Full install: deps + prompt to add PYTHONPATH |
133+
| `make install-deps` | Install dependencies from `requirements.txt` |
134+
| `make install-dev` | Install optional + dev dependencies |
135+
| `make env` | Check if PYTHONPATH is configured correctly |
136+
| `make env-persist` | Add PYTHONPATH to `~/.bashrc` or `~/.zshrc` |
71137

72138
## Logging Configuration
73139

74-
pyArgos uses a custom logging system with an `EXECUTION` log level (between DEBUG and INFO). The default configuration is loaded from:
140+
pyArgos uses a custom logging system with an `EXECUTION` log level (15, between DEBUG and INFO). The default configuration is loaded from:
75141

76142
```
77143
~/.pyargos/log/argosLogging.config
78144
```
79145

80-
If this file doesn't exist, pyArgos uses a sensible default configuration. See [Configuration Reference](configuration.md) for details on customizing logging.
146+
If this file doesn't exist, pyArgos creates it automatically from package defaults on first import. See [Configuration Reference](configuration.md) for details on customizing logging.
81147

82-
## Verifying the Installation
148+
## What's Next?
83149

84-
```python
85-
import argos
86-
print(argos.__version__) # Should print 1.2.3
87-
```
150+
- [Key Concepts](concepts.md) -- understand experiments, trials, devices, and how they connect
151+
- [Experiment Setup](experiment_setup.md) -- create and configure your first experiment
152+
- [CLI Reference](cli.md) -- all available command-line commands

0 commit comments

Comments
 (0)