gunrock / io

Input (scripts, etc.) and output (scripts, performance results, etc.) for Gunrock and other graph engines
10 stars 6 forks source link

Parser: CuSha's output has changed in the updated version #27

Closed neoblizz closed 7 years ago

neoblizz commented 7 years ago

In the updated CuSha (which is a lot cleaner and is what we used for new comparison tests), the generated output differs from what it was before. I have added the new txt2json code below for the parser, the commented segment is the old code. Would you like me to push this change or do we want to stay with the old one? @jowens

# Parser class for parsing CuSha output
class GPUEngineOutputParserCuSha(GPUEngineOutputParserBase):
        def __init__(self, input_path):
                super(GPUEngineOutputParserCuSha, self).__init__(input_path)
                self.regex_array = [{   "regex": re.compile("Input graph collected with ([0-9]+) vertices and ([0-9]+) edges."), 
                                        # re.compile("Graph is populated with ([0-9]+) vertices and ([0-9]+) edges."),
                                        "keys" : [{ "name" : "vertices_visited", "type" : "int"},
                                                  { "name" : "edges_visited", "type" : "int"},
                                                 ]
                                    },
                                    {   "regex": re.compile("Processing finished in (\d+(?:\.\d+)?) \(ms\)."), 
                                         # re.compile("Processing finished in : (\d+(?:\.\d+)?) \(ms\)"),
                                        "keys" : [{ "name" : "elapsed", "type" : "float"}]
                                    }
                ]
                self.engine = "CuSha"
jowens commented 7 years ago

As it seems like any current and future comparisons will be with the newer generated output, I would update the parser to handle it. We can always find the old stuff in source control if we need it.

neoblizz commented 7 years ago

Updated: https://github.com/gunrock/io/commit/df4268956058e4913c6afc2756b9ca191203157e