Version: May 4th, 2021
This tool is designed for automatically ILP scheduling to show ILP solving results.
It can take edgelist format DFG file as input, then transfer the graph file to ilp format as "ilp_output.lp" file to enable the GLPK solver for generating the scheduling result in "output.txt" file.
Latency L and memory M are 2 input arguments in our tool, which requires us to minimize the memory under latency L and minimize latency under memory M. We can use L and M for ML-RC scheduling or MR-LC scheduling.
glpk is used to solve the ILP formulations. To install, run the following command:
Once glpk is installed, we are ready to generate ILP files and solve them.
To generate an ILP file from the edgelist, use generate_ilp.py
:
python3 generate_ilp.py -i <input edgelist file name> -m <max memory usage requirement> -o <objective> -l <latency requirement>
OR
To generate an ILP file from the edgelist and feed to GLPK for solving, use edgelist_solve.sh
.
./edgelist_solve.sh -i <edgelist file name> -l <latenct constraint> -o <objective to minimize> -m <memory constraint> -f <optional output filename>
Note:
- Available objectives are (match case):
- latency
- memory
- If latency is the objective, then
-m
does not have to be specified.
Notice: We consider latency as a constraints since we don't want to make the file too large.
In this directory, we are using randomly generated edge-list files to run the program. One example could be:
./edgelist_solve.sh -i rand_DFG_s10_1.edgelist -m 50 -l 20 -o latency
This will generate an 'ilp_output.lp' file, then pipe this file to glpk for solving. The solved file will be placed in 'glpk_solved.txt'. This can be changed using the -f
flag, specifying an output name.
GLPK https://www.gnu.org/software/glpk/
https://pypi.org/project/glpk/
- Jake Steers: u1327208
- Ye Zhou: u1220084
- Zach Phelan: u1154147