Skip to content

Commit fa2847e

Browse files
committed
wip
1 parent 1d3b480 commit fa2847e

File tree

3 files changed

+37
-8
lines changed

3 files changed

+37
-8
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# Custom
2+
**-env/
3+
14
# Byte-compiled / optimized / DLL files
25
__pycache__/
36
*.py[cod]

README.md

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,46 @@
1-
# Bachelor Thesis: Spectrum Sensing for the SALSAT Nanosatellite
1+
# Spectrum Sensing for the SALSAT Nanosatellite
22

3-
This repository contains code for the Bachelor thesis *Spectrum Sensing for the SALSAT Nanosatellite*. It aims to provide algorithms and simulations for *blind wideband spectrum sensing* with special emphasis on space applications. More background information on the SALSAT project can be found [here](https://www.raumfahrttechnik.tu-berlin.de/menue/forschung/aktuelle_projekte/salsat/parameter/en/).
3+
This repository is part of my bachelor thesis: *Spectrum Sensing for the SALSAT Nanosatellite*. It provides algorithms and simulations for blind wideband spectrum sensing with special emphasis on space applications. More background information on the SALSAT project can be found [here](https://www.raumfahrttechnik.tu-berlin.de/menue/forschung/aktuelle_projekte/salsat/parameter/en/).
44

55
This repository is split up into two main directories:
66
* `specsens/` the python package that contains all relevant code and algorithms.
77
* `notebooks/` contains usage examples for all parts of the `specsens` package.
88

9-
Not relevant for *normal* use:
10-
* `graphs/` code that generates graphics for the thesis (LaTex).
11-
* `archive/` old code no longer relevant.
9+
## Usage
1210

13-
The code is written in `python 3.6` using the packages listed in [`requirements.txt`](./requirements.txt). **Ensure that you have matplotlib `3.1.x` installed. Other versions might give weird artifacts. I am still looking into the problem at this point in time.**
11+
The code is written in `python 3.6` using the packages listed in [`requirements.txt`](./requirements.txt). Consider using a [virtual environment](https://docs.python.org/3/tutorial/venv.html). **Ensure that you have matplotlib `3.1.x` installed. Other versions might give weird artifacts. I am still looking into the problem at this point in time.**
1412

15-
To run the notebooks you will need to install [Jupyter Notebook](https://jupyter.org/install.html).
13+
#### Step by step installation guide
14+
Starting with a *clean* Ubuntu 18.04 system (should also work with other Linux distributions) you will need to follow these steps:
15+
- Clone the repository using `git`, run `git clone <ssh url>`
16+
- Ensure you have Python 3, run `python3 --version`
17+
- Install Python Virtual Environments, run `sudo apt install python3-venv`
18+
- Install `pip3`, run `sudo apt install python3-pip`
19+
- Create a new virtual environment, run `python3 -m venv specsens-env`
20+
- To activate the virtual environment, run `source specsens-env/bin/activate`
21+
- (To deactivate the virtual environment, run `deactivate`)
22+
- Use the `requirements.txt` to install required python packages, run `pip3 install -r requirements.txt`
23+
- Finally, start Jupyter Notebook, run `jupyter notebook`
24+
25+
If you already have some of parts installed, just skip the corresponding steps. Feel free to open an issue or contact me if you run into any problems.
1626

1727
## Specsens Package
18-
In order to organize and structure my work I created the `specsens` package. It contains most of the algorithms and simulations that I developed. It behaves like a regular python package (`import specsens`) and consists of the following directories:
28+
In order to organize and structure my work I created the `specsens` package. It contains most of the algorithms and simulations that I developed. It behaves like a regular python package (one can just `import specsens`) and consists of the following directories:
1929
* `signal/` signal and noise generators used mainly for simulations, as well as some utilities that simplify working with signals.
2030
* `plot/` plotting functions to visualize signals.
2131
* `energy_detect/` energy detector and functions to calculate performance statistics (prob. of false alarm, prob. of detection, etc.).
2232
* `wideband_detect/` wideband detection algorithms (wideband energy detector, spectrum edge detector, etc.).
2333
* `eigenvalue_detect/` eigenvalue detection algorithms based on signal covariance matrices
2434
* `simulation/` simulations to evaluate performance statistics.
2535

36+
When using the `specsens` package locally you need to add the following lines before you import the package. This tells the python interpreter where to find the package:
37+
```python
38+
import sys
39+
sys.path.insert(0, '..')
40+
```
41+
Replace `..` with the path to the `specsens` package, when moving things around.
42+
43+
2644
## Notebooks
2745
**Coming soon**
2846

@@ -31,6 +49,7 @@ In order to organize and structure my work I created the `specsens` package. It
3149
- [] Notebook documentation in readme
3250
- [] Upload papers and create basic paper index that helps to *connect* paper and python implementation
3351
- [] Documentation for every function using sphinx(not sure if I will do that tho) (https://docs.python-guide.org/writing/documentation/)
52+
- [] Upload specsens to PyPi
3453

3554

3655
#### Functional
@@ -39,6 +58,7 @@ In order to organize and structure my work I created the `specsens` package. It
3958
- [] Add pfa and pd eigenvalue stats
4059
- [] Create eigenvalue simulation with filter and prewhitening matrix
4160
- [] Combine eigenvalue detection and noise estimation based energy detection, use energy detection as heuristic and binary search pattern to find *noise only* band to use for noise estimation
61+
- []
4262

4363
## Author
4464
Fabian Peddinghaus <[email protected]>

requirements.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
notebook==6.1.6
2+
numpy==1.19.5
3+
scipy==1.5.4
4+
matplotlib==3.1.3
5+
pywavelets==1.1.1
6+
tqdm==4.55.2

0 commit comments

Comments
 (0)