README.md 3.42 KB
Newer Older
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
1
# PSEUDo: Pattern Search, Exploration & Understanding for sequential Data Observer
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
2

Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
3
## Introduction
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
4
**PSEUDo** is an application that provides a way to search, explore and find interesting patterns in large multivariate time series data whilst giving a clear understanding of what's going on behind the scenes on the machine learning side. This is done by combining the vast knowledge of domain-experts with the immense processing power of computers, creating the interactive machine learning tool called **PSEUDo**.
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
5

Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
6
The application consists of two parts:
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
7
8
9
10
11
12
13
14
15
16
17
18
1. A client side, which is an Angular application
2. A server side, which is a Flask REST API written in Python

## Setup
To run the application, make sure you've installed the following:
1. Python >=3.5: https://www.python.org/downloads/
2. Flask: https://flask.palletsprojects.com/en/1.1.x/installation/
3. Angular: https://angular.io/guide/setup-local

Once these are installed on your computer, simply run *run-angular.bat* to set up the client side GUI 
and *run-flask.bat* to set up the server side API

Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
19
The client-side bat-file should automatically open your browser and connect to http://localhost:4200/
Kruyff,D.L.W. (Dylan)'s avatar
Kruyff,D.L.W. (Dylan) committed
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51

# Documentation
## GUI
The GUI is an Angular framework. It consists of views (components) and a state (service). Every time an API call is done, the state will alter. Using hooks (EventEmitters), views can subscribe state variable changes and alter their view using the new value(s). The types of views is listed below.
### Overview
This view shows the entire dataset. When windows are labeled and candidates are generated, it should show the locations in this overview.
### Query
This view shows the current query.
### Training
This view shows the sampled candidates. In this view the user can label the samples as correct or incorrect. When the user is satisfied the labels will be updated and new samples will be generated.
### Progress
This view will show the progress of the learned classifier. It should show whether the classifier is getting better at understanding the desired pattern
### Labels
This view shows the currently labeled windows. The user should be able to change and delete labels in this view.
### Settings
This view shows the current parameters (e.g. window size)

## API
### /read-data
This API call reads time series data from a file and returns the values and indices.
### /create-windows
This API call reads time series data and chunks it into windows. For now the windows are saved to a file locally.
### /initialize
This API call starts the first iteration of the LSH algorithm. First some essential parameters are calculated. Then the LSH algorithm is called. The API returns the candidates, distances and hash functions.
### /update
This API call runs the LSH algorithm with weights that will manipulate the hashing functions. The API returns the candidates, distances and hash functions.
### /query
This API will return the query data based on the provided window indices. If only one index is given, the API call will return the window values according to the index. If multiple indices are given, the DTW-based average of the window values according to the indices is returned.
### /window
This API simply returns the window values according to the index.
### /table-info
This API call will return extra info needed for the progression view. The input will be a subdivision of windows into buckets, and for each bucket the prototype (average) will be calculated + the distances between each prototype.