Skip to content

Commit

Permalink
cleaned up notebooks
Browse files Browse the repository at this point in the history
  • Loading branch information
karenl7 committed Aug 6, 2021
1 parent 2da6190 commit 0fde7bb
Show file tree
Hide file tree
Showing 28 changed files with 3,897 additions and 16 deletions.
19 changes: 4 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,11 @@
STLCG
======

A toolbox to compute the robustness of STL formulas using computations graphs (PyTorch).

The `wafr20` branch reproduces the results from our [WAFR2020 paper](http://asl.stanford.edu/wp-content/papercite-data/pdf/Leung.Arechiga.Pavone.WAFR20.pdf). Note that the stlcg code in the `master` and `dev` branches have been updated since. So the `wafr20` branch works in isolation.
A toolbox to compute the robustness of STL formulas using computations graphs.

## Installation
This was done on a linux machine running Python 3.5. You may need to change some of the packages in requirements to make it work on your setup. If you are running Python3.6 or higher, you may need to remove `importlib==1.0.4`.

First create a virtual environment
```
python3 -m venv stlcg-env
source stlcg-env/bin/activate
pip3 install -r requirements.txt
```
Then, since this project uses IPython notebooks, we'll install this conda environment as a kernel.
```
python3 -m ipykernel install --user --name stlcg-env --display-name "Python 3.X (stlcg)"
```
where X is the python3 version number.
You need Python3 and PyTorch installed.

The vizualization code here is constructed from https://github.com/szagoruyko/pytorchviz but with modifications to represent STL operators.

Expand All @@ -27,6 +14,8 @@ The vizualization code here is constructed from https://github.com/szagoruyko/py

`demo.ipynb` is an IPython jupyter notebook that showcases the basic functionality of the toolbox.

The `examples` folder contains example usage of STLCG in a number of applications. These are the examples investigated in the WAFR 2020 publication (see below).

## Publications
Here are a list of publications that use stlcg. Please file an issue, or pull request to add your publication to the list.

Expand Down
1,540 changes: 1,540 additions & 0 deletions examples/Motion planning.ipynb

Large diffs are not rendered by default.

1,185 changes: 1,185 additions & 0 deletions examples/Neural networks.ipynb

Large diffs are not rendered by default.

1,166 changes: 1,166 additions & 0 deletions examples/VAE.ipynb

Large diffs are not rendered by default.

Binary file added examples/models/bump.npy
Binary file not shown.
Binary file added examples/models/bump_0.00.model
Binary file not shown.
Binary file added examples/models/bump_2.00.model
Binary file not shown.
Binary file added examples/models/bump_data_0.00.npy
Binary file not shown.
Binary file added examples/models/bump_data_2.00.npy
Binary file not shown.
Binary file added examples/models/intent_0.00.model
Binary file not shown.
Binary file added examples/models/intent_0.10.model
Binary file not shown.
Binary file added examples/models/intent_test.npy
Binary file not shown.
Binary file added examples/models/intent_train.npy
Binary file not shown.
Binary file added examples/models/phi1_margin=0.0.npy
Binary file not shown.
Binary file added examples/models/phi1_margin=0.05.npy
Binary file not shown.
Binary file added examples/models/phi2_margin=0.0.npy
Binary file not shown.
Binary file added examples/models/phi2_margin=0.05.npy
Binary file not shown.
Binary file added examples/models/psi1_margin=0.0.npy
Binary file not shown.
Binary file added examples/models/psi1_margin=0.05.npy
Binary file not shown.
Binary file added examples/models/psi2_margin=0.0.npy
Binary file not shown.
Binary file added examples/models/psi2_margin=0.05.npy
Binary file not shown.
Binary file added examples/models/stlvae.model
Binary file not shown.
Binary file added examples/models/stlvae_stl_loss.npy
Binary file not shown.
Binary file added examples/models/stlvae_train_loss.npy
Binary file not shown.
Binary file added examples/models/stlvae_vae_loss.npy
Binary file not shown.
Binary file added examples/models/vae.model
Binary file not shown.
Binary file added examples/models/vae_train_loss.npy
Binary file not shown.
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
name="stlcg",
version="0.0.1",
author="Karen Leung and Nikos Arechiga",
author_email="[email protected] and [email protected]",
author_email="[email protected] and [email protected]",
description="A toolbox to compute the robustness of STL formulas using computations graphs (PyTorch).",
long_description=long_description,
long_description_content_type="text/markdown",
Expand All @@ -19,3 +19,4 @@
"Operating System :: OS Independent",
],
)

0 comments on commit 0fde7bb

Please sign in to comment.