From 8733cbc8a79f58f2c4400aef1d4d0bf6426f9607 Mon Sep 17 00:00:00 2001
From: Samuel Gaist <samuel.gaist@idiap.ch>
Date: Mon, 28 May 2018 10:16:20 +0200
Subject: [PATCH] [algorithm] Improved documentation and added missing parts

---
 beat/backend/python/algorithm.py | 18 +++++++++++++++---
 1 file changed, 15 insertions(+), 3 deletions(-)

diff --git a/beat/backend/python/algorithm.py b/beat/backend/python/algorithm.py
index 3eaa746..98bc551 100644
--- a/beat/backend/python/algorithm.py
+++ b/beat/backend/python/algorithm.py
@@ -81,14 +81,14 @@ class Runner(object):
       module (:std:term:`module`): The preloaded module containing the
         algorithm as returned by :py:func:`.loader.load_module`.
 
-      obj_name (str): The name of the object within the module you're interested
-        on
+      obj_name (str): The name of the object within the module you're
+        interested on
 
       algorithm (object): The algorithm instance that is used for parameter
         checking.
 
       exc (:std:term:`class`): The class to use as base exception when
-        translating the exception from the user code. Read the documention of
+        translating the exception from the user code. Read the documentation of
         :py:func:`.loader.run` for more details.
 
     '''
@@ -498,6 +498,11 @@ class Algorithm(object):
 
     @name.setter
     def name(self, value):
+        """Sets the name of this object
+
+        Parameters:
+            name (str): Name of this object
+        """
 
         if self.data['language'] == 'unknown':
             raise RuntimeError("algorithm has no programming language set")
@@ -616,11 +621,15 @@ class Algorithm(object):
 
     @property
     def isAnalyzer(self):
+        """Returns whether this algorithms is an analyzer"""
+
         return (self.results is not None)
 
 
     @property
     def results(self):
+        """The results of this algorithm"""
+
         return self.data.get('results')
 
 
@@ -632,6 +641,8 @@ class Algorithm(object):
 
     @property
     def parameters(self):
+        """The parameters of this algorithm"""
+
         return self.data.get('parameters')
 
 
@@ -643,6 +654,7 @@ class Algorithm(object):
 
     @property
     def splittable(self):
+        """Whether this algorithm can be split between several processes"""
         return self.data.get('splittable', False)
 
 
-- 
GitLab