Skip to content
Snippets Groups Projects
Commit 177c4903 authored by Maël Madon's avatar Maël Madon
Browse files

rename to make tests work. Explain new install in README

parent fabdf64c
Branches
Tags
No related merge requests found
Pipeline #5529 failed
......@@ -14,19 +14,36 @@ The idea behind it is to keep the *logic* of user submissions rather than the ex
## Usage
## Installation
Installation with `pip` without cloning:
```terminal
pip install git+https://gitlab.irit.fr/sepia-pub/mael/swf2userSessions
```
Clone and install with `flit`:
```terminal
git clone https://gitlab.irit.fr/sepia-pub/mael/swf2userSessions
cd swf2userSessions
flit install
```
You can then run the app from CLI by simply calling `swf2userSessions`.
You can also clone the repository and directly execute the main script `python3 swf2userSessions/swf2sessions.py`.
Requirements:
- python3
- [networkx](https://github.com/networkx/networkx) (optional, for the graph outputs): `pip3 install networkx`
- [pytest](https://pytest.org/) (optional, for the tests): `pip3 install pytest`
## Usage
To run the session decomposition on the workload `workloads/example.swf` illustrated above, with "Arrival" delimitation approach and a threshold of 60 minutes:
```terminal
python3 swf2userSessions.py -a 60 workloads/example.swf out/
swf2userSessions -a 60 workloads/example.swf out/
```
For more documentation, see: `python3 swf2userSessions.py -h`
For more documentation, see: `swf2userSessions -h`
## Example
......
......@@ -18,4 +18,4 @@ classifiers = [
]
[project.scripts]
swf2userSessions = "swf2userSessions.swf2userSessions:parse_from_cli"
\ No newline at end of file
swf2userSessions = "swf2userSessions.swf2sessions:parse_from_cli"
\ No newline at end of file
......@@ -232,4 +232,4 @@ def parse_from_cli():
if __name__ == "__main__":
main()
\ No newline at end of file
parse_from_cli()
\ No newline at end of file
......@@ -30,7 +30,7 @@ def run_script(delim, threshold,
out_dir = os.path.abspath(f'test-out/{test_name}')
create_dir_rec_if_needed(out_dir)
args = ['python3', 'swf2userSessions.py', f'--{delim}', str(threshold),
args = ['python3', 'swf2userSessions/swf2sessions.py', f'--{delim}', str(threshold),
'-q', input_swf, out_dir]
if graph:
args.append("--graph")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment