Add benchmark running to the pipeline
This commit is contained in:
parent
0cd83fedd9
commit
f2638ab74f
@ -28,3 +28,6 @@ jobs:
|
||||
|
||||
- name: Run tests
|
||||
run: julia --project -e 'import Pkg; Pkg.test()'
|
||||
|
||||
- name: Run examples
|
||||
run: julia --project -e 'import Pkg; include("examples/import_bench.jl")'
|
||||
|
@ -1,4 +1,4 @@
|
||||
using metagraph_optimization
|
||||
using MetagraphOptimization
|
||||
|
||||
function main()
|
||||
graph = DAG()
|
||||
|
@ -8,6 +8,10 @@ function bench_txt(filepath::String, bench::Bool = true)
|
||||
name, _ = splitext(name)
|
||||
|
||||
filepath = joinpath(@__DIR__, filepath)
|
||||
if !isfile(filepath)
|
||||
println("File ", filepath, " does not exist, skipping bench")
|
||||
return
|
||||
end
|
||||
|
||||
println(name, ":")
|
||||
g = import_txt(filepath)
|
||||
|
@ -1,21 +1,4 @@
|
||||
module MetagraphOptimization
|
||||
import Base.show
|
||||
import Base.==
|
||||
import Base.in
|
||||
import Base.copy
|
||||
|
||||
include("tasks.jl")
|
||||
include("nodes.jl")
|
||||
include("graph.jl")
|
||||
include("task_functions.jl")
|
||||
include("node_functions.jl")
|
||||
include("graph_functions.jl")
|
||||
include("graph_operations.jl")
|
||||
include("import.jl")
|
||||
include("utility.jl")
|
||||
|
||||
include("abc_model/tasks.jl")
|
||||
include("abc_model/task_functions.jl")
|
||||
|
||||
export Node, Edge, ComputeTaskNode, DataTaskNode, DAG
|
||||
export AbstractTask, AbstractComputeTask, AbstractDataTask, DataTask, ComputeTaskP, ComputeTaskS1, ComputeTaskS2, ComputeTaskV, ComputeTaskU, ComputeTaskSum, FusedComputeTask
|
||||
@ -27,4 +10,25 @@ export ==, in, show
|
||||
|
||||
export bytes_to_human_readable
|
||||
|
||||
|
||||
import Base.show
|
||||
import Base.==
|
||||
import Base.in
|
||||
import Base.copy
|
||||
|
||||
|
||||
include("tasks.jl")
|
||||
include("nodes.jl")
|
||||
include("graph.jl")
|
||||
|
||||
include("task_functions.jl")
|
||||
include("node_functions.jl")
|
||||
include("graph_functions.jl")
|
||||
include("graph_operations.jl")
|
||||
include("import.jl")
|
||||
include("utility.jl")
|
||||
|
||||
include("abc_model/tasks.jl")
|
||||
include("abc_model/task_functions.jl")
|
||||
|
||||
end # module MetagraphOptimization
|
||||
|
14
src/graph.jl
14
src/graph.jl
@ -51,18 +51,18 @@ end
|
||||
|
||||
|
||||
mutable struct PossibleOperations
|
||||
nodeFusions::Vector{NodeFusion}
|
||||
nodeReductions::Vector{NodeReduction}
|
||||
nodeSplits::Vector{NodeSplit}
|
||||
nodeFusions::Set{NodeFusion}
|
||||
nodeReductions::Set{NodeReduction}
|
||||
nodeSplits::Set{NodeSplit}
|
||||
dirty::Bool
|
||||
end
|
||||
|
||||
function PossibleOperations()
|
||||
return PossibleOperations(
|
||||
Vector{NodeFusion}(),
|
||||
Vector{NodeReduction}(),
|
||||
Vector{NodeSplit}(),
|
||||
false
|
||||
Set{NodeFusion}(),
|
||||
Set{NodeReduction}(),
|
||||
Set{NodeSplit}(),
|
||||
true
|
||||
)
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user