[mlpack-svn] r15772 - mlpack/conf/jenkins-conf/benchmark/util
fastlab-svn at coffeetalk-1.cc.gatech.edu
fastlab-svn at coffeetalk-1.cc.gatech.edu
Fri Sep 13 12:29:19 EDT 2013
Author: marcus
Date: Fri Sep 13 12:29:18 2013
New Revision: 15772
Log:
Clean and add additional comments.
Modified:
mlpack/conf/jenkins-conf/benchmark/util/convert.py
mlpack/conf/jenkins-conf/benchmark/util/database.py
mlpack/conf/jenkins-conf/benchmark/util/graph.py
mlpack/conf/jenkins-conf/benchmark/util/loader.py
mlpack/conf/jenkins-conf/benchmark/util/log.py
mlpack/conf/jenkins-conf/benchmark/util/misc.py
mlpack/conf/jenkins-conf/benchmark/util/parser.py
Modified: mlpack/conf/jenkins-conf/benchmark/util/convert.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/convert.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/convert.py Fri Sep 13 12:29:18 2013
@@ -25,8 +25,8 @@
'''
Convert dataset to a file with the given extension.
- @para dataset - Convert this dataset.
- @para extension - Convert dataset to a new file with this extension.
+ @param dataset - Convert this dataset.
+ @param extension - Convert dataset to a new file with this extension.
'''
def __init__(self, dataset, extension):
self.extension = extension
@@ -37,8 +37,8 @@
'''
Decide which method we have to call to modify the dataset.
- @para dataset - Convert this dataset.
- @para extension - Convert dataset to a new file with this extension.
+ @param dataset - Convert this dataset.
+ @param extension - Convert dataset to a new file with this extension.
'''
def ModifyDataset(self, dataset, extension):
dataExtension = os.path.splitext(dataset)[1][1:]
@@ -53,8 +53,8 @@
'''
Add an header to the dataset file.
- @para data - This dataset contains the information.
- @para newData - This dataset contais the information and the header.
+ @param data - This dataset contains the information.
+ @param newData - This dataset contais the information and the header.
'''
def AddArffHeader(self, data, newData):
# Extract the dataset name.
Modified: mlpack/conf/jenkins-conf/benchmark/util/database.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/database.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/database.py Fri Sep 13 12:29:18 2013
@@ -149,6 +149,7 @@
Add a new build record to the builds table.
@param libaryId - The id of the library.
+ @return The new build id.
'''
def NewBuild(self, libaryId):
with self.con:
@@ -188,7 +189,7 @@
'''
Get the informations of the given build.
- @param id - The if of the build.
+ @param id - The id of the build.
@return The records.
'''
def GetBuild(self, id):
@@ -230,9 +231,9 @@
@param methodId - The id of the method.
'''
def NewResult(self, buildId, libaryId, time, var, datasetId, methodId):
- with self.con:
+ with self.con:
self.cur.execute("INSERT INTO results VALUES (NULL,?,?,?,?,?,?)",
- (buildId, libaryId, time, var, datasetId, methodId))
+ (buildId, libaryId, time, var, datasetId, methodId))
'''
Get the method id from the methods table with the given name and parameters.
@@ -347,6 +348,7 @@
'''
Add a new memory record to the memory table.
+ @param buildId - The build id.
@param libaryId - The id ot the library.
@param methodId - The id of the method
@param datasetId - The id of the dataset.
Modified: mlpack/conf/jenkins-conf/benchmark/util/graph.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/graph.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/graph.py Fri Sep 13 12:29:18 2013
@@ -41,6 +41,7 @@
@param bestlib - The name of the library which should be compared with the other
libraries.
@param backgroundColor - The color of the image background.
+ at return Result informations.
'''
def GenerateBarChart(results, libraries, fileName, bestlib="mlpack",
backgroundColor="#FFFFFF"):
@@ -200,6 +201,8 @@
@param data - List which contains the values for the line chart.
@param fileName - The filename of the line chart.
@param backgroundColor - The color of the image background.
+ at param windowWidth - The width of the chart.
+ at prama windowHeight - The height of the chart.
'''
def GenerateSingleLineChart(data, fileName, backgroundColor="#FFFFFF",
windowWidth=8.1, windowHeight=1.3):
Modified: mlpack/conf/jenkins-conf/benchmark/util/loader.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/loader.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/loader.py Fri Sep 13 12:29:18 2013
@@ -15,6 +15,8 @@
'''
Import a module from a path.
+
+ @param path - The path to the module.
'''
@staticmethod
def ImportModuleFromPath(path):
Modified: mlpack/conf/jenkins-conf/benchmark/util/log.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/log.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/log.py Fri Sep 13 12:29:18 2013
@@ -91,6 +91,7 @@
Truncate the String into lines of 80 characters.
@param line - The line to wrap.
+ @return The truncated string.
'''
@staticmethod
def WrapLine(line):
Modified: mlpack/conf/jenkins-conf/benchmark/util/misc.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/misc.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/misc.py Fri Sep 13 12:29:18 2013
@@ -81,6 +81,7 @@
@param dataMatrix - In this Matrix we search for the right position.
@param datasetName - Name of the dataset.
@param datasetCount - Maximum dataset count.
+ at return The correct row.
'''
def FindRightRow(dataMatrix, datasetName, datasetCount):
for row in range(datasetCount):
@@ -91,7 +92,7 @@
Collect informations for the given dataset.
@param path - Path to the dataset.
- at return Tuble which contains the informations about the given dataset.
+ at return Tuple which contains the informations about the given dataset.
'''
def DatasetInfo(path):
if not isinstance(path, str):
Modified: mlpack/conf/jenkins-conf/benchmark/util/parser.py
==============================================================================
--- mlpack/conf/jenkins-conf/benchmark/util/parser.py (original)
+++ mlpack/conf/jenkins-conf/benchmark/util/parser.py Fri Sep 13 12:29:18 2013
@@ -159,10 +159,11 @@
'''
Show a value is not set warn message.
+
@param key - The name of the key.
@param streamNum - The number of the stream.
'''
- def KeyWarnMsg(self, key, streamNum = 0):
+ def KeyWarnMsg(self, key, streamNum=0):
if streamNum == 0:
Log.Warn("No [" + key + "] key, use default value.", self.verbose)
else:
More information about the mlpack-svn
mailing list