Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OptLP
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PMC-SOG
OptLP
Commits
0d05e93b
Commit
0d05e93b
authored
4 months ago
by
Jaime Arias
Browse files
Options
Downloads
Patches
Plain Diff
doc: update README
parent
de4e8559
No related branches found
Branches containing commit
Tags
v2.4.2rc3
Tags containing commit
No related merge requests found
Pipeline
#8806
passed with stages
in 7 minutes and 36 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+22
-18
22 additions, 18 deletions
README.md
with
22 additions
and
18 deletions
README.md
+
22
−
18
View file @
0d05e93b
...
...
@@ -11,8 +11,7 @@ optimal solution of a graph from a `.dot` file. It provides the following
functionalities:
1.
**Generate a Random Graph**
: Users can specify the number of nodes, edges,
and labels to generate a random, deterministic, and connected graph. This is
achieved using the
`generateRandomGraph`
function in
`Graph.cpp`
.
and labels to generate a random, deterministic, and connected graph.
2.
**Extract Optimal Solution from a .dot File**
: Users can provide a
`.dot`
file to extract and optimize the graph.
...
...
@@ -20,14 +19,13 @@ file to extract and optimize the graph.
After generating the graph or loading it from a file, the program performs the
following steps:
1.
**Generate Regular Expression of the Graph**
: The
`RegularExpressionGeneration`
function in
`graph.cpp`
is used to generate the
1.
**Generate Regular Expression of the Graph**
: The tool generates the
regular expression of the graph.
2.
**Extract All Paths from the Regular Expression**
: All the paths of the graph
are extracted from the regular expression.
3.
**Pass to the Linear Program**
:
3.
**Pass to the
Integer
Linear Program**
:
-
**Variables**
: Paths of the graph.
-
**Constraints**
: Labels representing transitions in the graph.
...
...
@@ -54,7 +52,8 @@ the selected paths.
Make sure to install the necessary dependencies before running the program:
-
`gcc`
>= 9.3.0
-
`cmake`
-
`cmake`
>= 3.18
-
`ninja`
## Build
...
...
@@ -83,9 +82,9 @@ cd assets
To generate a random graph, use the following options:
```
sh
./optlp
--nb-nodes
<n>
\
--nb-edges
<m>
\
--nb-labels
<l>
./optlp
random
--nb-nodes
<n>
\
--nb-edges
<m>
\
--nb-labels
<l>
```
where:
...
...
@@ -97,7 +96,7 @@ where:
**Example:**
```
sh
./optlp
--nb-nodes
200
--nb-edges
100
--nb-labels
20
./optlp
random
--nb-nodes
200
--nb-edges
100
--nb-labels
20
```
### Extracting the Optimal Solution from a .dot File
...
...
@@ -106,18 +105,18 @@ To extract the optimal solution of a graph from a `.dot` file, use the following
option:
```
sh
./optlp
--input-file
<filename.dot>
--output-folder
<foldername>
./optlp
from-file
--input-file
<filename.dot>
--output-folder
<folder
name>
```
where:
-
`--input-file <filename.dot>`
: Specifies the .dot file containing the graph.
-
`--output-folder <foldername>`
: Specifies the folder containing the result.
-
`--output-folder <folder
name>`
: Specifies the folder containing the result.
**Example:**
```
sh
./optlp
--input-file
./toys_examples/graph3.dot
--output-folder
./result/
./optlp
from-file
--input-file
./toys_examples/graph3.dot
--output-folder
./result/
```
### Help
...
...
@@ -132,9 +131,14 @@ display a help message with usage instructions.
The help message will display the following:
```
sh
/
**************************************************************
/
/
********************
help
********************
/
/
-To
generate a random graph: use the options
--nb-nodes
<n>
--nb-edges
<m>
--nb-labels
<l>
-To
extract the optimal solution of a .dot file: use the option
-d
<filename.dot>
/
**************************************************************
/
❯ ./assets/optlp
--help
OptLP: A tool to find the minimum number of shortest paths that cover all system actions
Usage: ./assets/optlp
[
OPTIONS]
[
SUBCOMMAND]
Options:
-h
,--help Print this
help
message and
exit
Subcommands:
random Generate a random LTS
from-file Load an LTS from a dot file
```
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment