diff --git a/build.xml b/build.xml index af2bcd0..364d277 100644 --- a/build.xml +++ b/build.xml @@ -29,7 +29,13 @@ - + + + + + + + diff --git a/doc/bin.__init__.html b/doc/bin.__init__.html index a6a7745..2fec622 100644 --- a/doc/bin.__init__.html +++ b/doc/bin.__init__.html @@ -8,7 +8,7 @@  
 
bin.__init__
index
/home/airballman/documents/workspace/Tippy/bin/__init__.py
+>index
/home/jlengrand/git/Tippy/bin/__init__.py

##---
# jlengrand
#Created on : Thu Oct 27 14:00:20 CEST 2011
diff --git a/doc/bin.html b/doc/bin.html index d1d4ca2..3abf107 100644 --- a/doc/bin.html +++ b/doc/bin.html @@ -8,7 +8,7 @@  
 
bin
index
/home/airballman/documents/workspace/Tippy/bin/__init__.py
+>index
/home/jlengrand/git/Tippy/bin/__init__.py

##---
# jlengrand
#Created on : Thu Oct 27 14:00:20 CEST 2011
diff --git a/doc/examples.__init__.html b/doc/examples.__init__.html index 8793ec9..7408e12 100644 --- a/doc/examples.__init__.html +++ b/doc/examples.__init__.html @@ -8,7 +8,7 @@  
 
examples.__init__
index
/home/airballman/documents/workspace/Tippy/examples/__init__.py
+>index
/home/jlengrand/git/Tippy/examples/__init__.py

\ No newline at end of file diff --git a/doc/examples.html b/doc/examples.html index 3c0c830..f57724f 100644 --- a/doc/examples.html +++ b/doc/examples.html @@ -8,7 +8,7 @@  
 
examples
index
/home/airballman/documents/workspace/Tippy/examples/__init__.py
+>index
/home/jlengrand/git/Tippy/examples/__init__.py

diff --git a/doc/tippy.__init__.html b/doc/tippy.__init__.html index 9bee35b..5aa0eaa 100644 --- a/doc/tippy.__init__.html +++ b/doc/tippy.__init__.html @@ -8,7 +8,7 @@
 
 
tippy.__init__
index
/home/airballman/documents/workspace/Tippy/tippy/__init__.py
+>index
/home/jlengrand/git/Tippy/tippy/__init__.py

\ No newline at end of file diff --git a/doc/tippy.basic_operations.html b/doc/tippy.basic_operations.html index 4b18a77..d583f59 100644 --- a/doc/tippy.basic_operations.html +++ b/doc/tippy.basic_operations.html @@ -8,7 +8,7 @@  
 
tippy.basic_operations
index
/home/airballman/documents/workspace/Tippy/tippy/basic_operations.py
+>index
/home/jlengrand/git/Tippy/tippy/basic_operations.py

Contains all basic functions, such as image creation, copy, . . .
No Image processing complex algorithms here. 
 
diff --git a/doc/tippy.display_operations.html b/doc/tippy.display_operations.html index 6206e74..072d575 100644 --- a/doc/tippy.display_operations.html +++ b/doc/tippy.display_operations.html @@ -8,7 +8,7 @@  
 
tippy.display_operations
index
/home/airballman/documents/workspace/Tippy/tippy/display_operations.py
+>index
/home/jlengrand/git/Tippy/tippy/display_operations.py

Contains all functions related to graphical display.
 
Created on Nov 19, 2011
diff --git a/doc/tippy.html b/doc/tippy.html index ffa32dc..2ad44cf 100644 --- a/doc/tippy.html +++ b/doc/tippy.html @@ -8,7 +8,7 @@  
 
tippy
index
/home/airballman/documents/workspace/Tippy/tippy/__init__.py
+>index
/home/jlengrand/git/Tippy/tippy/__init__.py

diff --git a/doc/tippy.segmentations.html b/doc/tippy.segmentations.html index 4e9f555..03f2e65 100644 --- a/doc/tippy.segmentations.html +++ b/doc/tippy.segmentations.html @@ -8,7 +8,7 @@
 
 
tippy.segmentations
index
/home/airballman/documents/workspace/Tippy/tippy/segmentations.py
+>index
/home/jlengrand/git/Tippy/tippy/segmentations.py

This method contains all functions segmentation related.
 
Created on Nov 26, 2011
diff --git a/doc/tippy.tests.__init__.html b/doc/tippy.tests.__init__.html index e2cb2b8..56ba028 100644 --- a/doc/tippy.tests.__init__.html +++ b/doc/tippy.tests.__init__.html @@ -8,7 +8,7 @@  
 
tippy.tests.__init__
index
/home/airballman/documents/workspace/Tippy/tippy/tests/__init__.py
+>index
/home/jlengrand/git/Tippy/tippy/tests/__init__.py

\ No newline at end of file diff --git a/doc/tippy.tests.html b/doc/tippy.tests.html index 2a27341..2aa1a2b 100644 --- a/doc/tippy.tests.html +++ b/doc/tippy.tests.html @@ -8,7 +8,7 @@  
 
tippy.tests
index
/home/airballman/documents/workspace/Tippy/tippy/tests/__init__.py
+>index
/home/jlengrand/git/Tippy/tippy/tests/__init__.py

diff --git a/doc/tippy.tests.test_basic_operations.html b/doc/tippy.tests.test_basic_operations.html index 81e7677..ac234b5 100644 --- a/doc/tippy.tests.test_basic_operations.html +++ b/doc/tippy.tests.test_basic_operations.html @@ -8,7 +8,7 @@
 
 
tippy.tests.test_basic_operations
index
/home/airballman/documents/workspace/Tippy/tippy/tests/test_basic_operations.py
+>index
/home/jlengrand/git/Tippy/tippy/tests/test_basic_operations.py

Contains all tests for basic_operations module
 
Created on Nov 19, 2011
@@ -33,7 +33,7 @@ Created on Nov 19, 2011
       

-
unittest.TestCase(__builtin__.object) +
unittest.case.TestCase(__builtin__.object)
Test @@ -44,14 +44,14 @@ Created on Nov 19, 2011
+class Test(unittest.case.TestCase)
 
-class Test(unittest.TestCase)
    The class inherits from unittest
 
 
Method resolution order:
Test
-
unittest.TestCase
+
unittest.case.TestCase
__builtin__.object

@@ -66,7 +66,7 @@ Methods defined here:
test_mouse_point(self)

-Methods inherited from unittest.TestCase:
+Methods inherited from unittest.case.TestCase:
__call__(self, *args, **kwds)
__eq__(self, other)
@@ -83,58 +83,203 @@ not have a method with the specified name.
__str__(self)
-
assertAlmostEqual = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
addCleanup(self, function, *args, **kwargs)
Add a function, with arguments, to be called when the test is
+completed. Functions added are called on a LIFO basis and are
+called after tearDown on test failure or success.

+Cleanup items are called even if setUp fails (unlike tearDown).
+ +
addTypeEqualityFunc(self, typeobj, function)
Add a type specific assertEqual style function to compare a type.

+This method is for use by TestCase subclasses that need to register
+their own type equality functions to provide nicer error messages.

+Args:
+    typeobj: The data type to call this function on when both values
+            are of the same type in assertEqual().
+    function: The callable taking two arguments and an optional
+            msg= argument that raises self.failureException with a
+            useful error message when the two arguments are not equal.
+ +
assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertAlmostEquals = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
assertAlmostEquals = assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertEqual = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertDictContainsSubset(self, expected, actual, msg=None)
Checks whether actual is a superset of expected.
+ +
assertDictEqual(self, d1, d2, msg=None)
+ +
assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertEquals = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertEquals = assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertFalse = failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
assertFalse(self, expr, msg=None)
Check that the expression is false.
-
assertNotAlmostEqual = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertGreater(self, a, b, msg=None)
Just like assertTrue(a > b), but with a nicer default message.
+ +
assertGreaterEqual(self, a, b, msg=None)
Just like assertTrue(a >= b), but with a nicer default message.
+ +
assertIn(self, member, container, msg=None)
Just like assertTrue(a in b), but with a nicer default message.
+ +
assertIs(self, expr1, expr2, msg=None)
Just like assertTrue(a is b), but with a nicer default message.
+ +
assertIsInstance(self, obj, cls, msg=None)
Same as assertTrue(isinstance(obj, cls)), with a nicer
+default message.
+ +
assertIsNone(self, obj, msg=None)
Same as assertTrue(obj is None), with a nicer default message.
+ +
assertIsNot(self, expr1, expr2, msg=None)
Just like assertTrue(a is not b), but with a nicer default message.
+ +
assertIsNotNone(self, obj, msg=None)
Included for symmetry with assertIsNone.
+ +
assertItemsEqual(self, expected_seq, actual_seq, msg=None)
An unordered sequence specific comparison. It asserts that
+actual_seq and expected_seq have the same element counts.
+Equivalent to::

+    assertEqual(Counter(iter(actual_seq)),
+                     Counter(iter(expected_seq)))

+Asserts that each element has the same count in both sequences.
+Example:
+    - [0, 1, 1] and [1, 0, 1] compare equal.
+    - [0, 0, 1] and [0, 1] compare unequal.
+ +
assertLess(self, a, b, msg=None)
Just like assertTrue(a < b), but with a nicer default message.
+ +
assertLessEqual(self, a, b, msg=None)
Just like assertTrue(a <= b), but with a nicer default message.
+ +
assertListEqual(self, list1, list2, msg=None)
A list-specific equality assertion.

+Args:
+    list1: The first list to compare.
+    list2: The second list to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertMultiLineEqual(self, first, second, msg=None)
Assert that two multi-line strings are equal.
+ +
assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotAlmostEquals = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertNotAlmostEquals = assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotEqual = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertNotEquals = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEquals = assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertRaises = failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
+
assertNotIn(self, member, container, msg=None)
Just like assertTrue(a not in b), but with a nicer default message.
+ +
assertNotIsInstance(self, obj, cls, msg=None)
Included for symmetry with assertIsInstance.
+ +
assertNotRegexpMatches(self, text, unexpected_regexp, msg=None)
Fail the test if the text matches the regular expression.
+ +
assertRaises(self, excClass, callableObj=None, *args, **kwargs)
Fail unless an exception of class excClass is thrown
by callableObj when invoked with arguments args and keyword
arguments kwargs. If a different type of exception is
thrown, it will not be caught, and the test case will be
deemed to have suffered an error, exactly as for an
-unexpected exception.
+unexpected exception.

+If called with callableObj omitted or None, will return a
+context object used like this::

+     with assertRaises(SomeException):
+         do_something()

+The context manager keeps a reference to the exception as
+the 'exception' attribute. This allows you to inspect the
+exception after the assertion::

+    with assertRaises(SomeException) as cm:
+        do_something()
+    the_exception = cm.exception
+    assertEqual(the_exception.error_code, 3)
-
assertTrue = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRaisesRegexp(self, expected_exception, expected_regexp, callable_obj=None, *args, **kwargs)
Asserts that the message in a raised exception matches a regexp.

+Args:
+    expected_exception: Exception class expected to be raised.
+    expected_regexp: Regexp (re pattern object or string) expected
+            to be found in error message.
+    callable_obj: Function to be called.
+    args: Extra args.
+    kwargs: Extra kwargs.
-
assert_ = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRegexpMatches(self, text, expected_regexp, msg=None)
Fail the test unless the text matches the regular expression.
+ +
assertSequenceEqual(self, seq1, seq2, msg=None, seq_type=None)
An equality assertion for ordered sequences (like lists and tuples).

+For the purposes of this function, a valid ordered sequence type is one
+which can be indexed, has a length, and has an equality operator.

+Args:
+    seq1: The first sequence to compare.
+    seq2: The second sequence to compare.
+    seq_type: The expected datatype of the sequences, or None if no
+            datatype should be enforced.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertSetEqual(self, set1, set2, msg=None)
A set-specific equality assertion.

+Args:
+    set1: The first set to compare.
+    set2: The second set to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.

+assertSetEqual uses ducktyping to support different types of sets, and
+is optimized for sets specifically (parameters must support a
+difference method).
+ +
assertTrue(self, expr, msg=None)
Check that the expression is true.
+ +
assertTupleEqual(self, tuple1, tuple2, msg=None)
A tuple-specific equality assertion.

+Args:
+    tuple1: The first tuple to compare.
+    tuple2: The second tuple to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assert_ = assertTrue(self, expr, msg=None)
Check that the expression is true.
countTestCases(self)
@@ -142,38 +287,24 @@ unexpected exception.
defaultTestResult(self)
+
doCleanups(self)
Execute all cleanup functions. Normally called for you after
+tearDown.
+
fail(self, msg=None)
Fail immediately, with the given message.
-
failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
failIf = deprecated_func(*args, **kwargs)
-
failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failIfAlmostEqual = deprecated_func(*args, **kwargs)
-
failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
-operator.
+
failIfEqual = deprecated_func(*args, **kwargs)
-
failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
failUnless = deprecated_func(*args, **kwargs)
-
failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failUnlessAlmostEqual = deprecated_func(*args, **kwargs)
-
failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
-operator.
+
failUnlessEqual = deprecated_func(*args, **kwargs)
-
failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
-by callableObj when invoked with arguments args and keyword
-arguments kwargs. If a different type of exception is
-thrown, it will not be caught, and the test case will be
-deemed to have suffered an error, exactly as for an
-unexpected exception.
+
failUnlessRaises = deprecated_func(*args, **kwargs)
id(self)
@@ -185,8 +316,16 @@ description has been provided.
The default implementation of this method returns the first line of
the specified test method's docstring.
+
skipTest(self, reason)
Skip this test.
+
-Data descriptors inherited from unittest.TestCase:
+Class methods inherited from unittest.case.TestCase:
+
setUpClass(cls) from __builtin__.type
Hook method for setting up class fixture before running tests in the class.
+ +
tearDownClass(cls) from __builtin__.type
Hook method for deconstructing the class fixture after running all tests in the class.
+ +
+Data descriptors inherited from unittest.case.TestCase:
__dict__
dictionary for instance variables (if defined)
@@ -194,8 +333,12 @@ Data descriptors inherited from unittest.TestCa
list of weak references to the object (if defined)

-Data and other attributes inherited from
unittest.TestCase:
+Data and other attributes inherited from unittest.case.TestCase:
failureException = <type 'exceptions.AssertionError'>
Assertion failed.
+
longMessage = False
+ +
maxDiff = 640
+
\ No newline at end of file diff --git a/doc/tippy.tests.test_display_operations.html b/doc/tippy.tests.test_display_operations.html index 6b331ca..1fbd3a7 100644 --- a/doc/tippy.tests.test_display_operations.html +++ b/doc/tippy.tests.test_display_operations.html @@ -8,7 +8,7 @@  
 
tippy.tests.test_display_operations
index
/home/airballman/documents/workspace/Tippy/tippy/tests/test_display_operations.py
+>index
/home/jlengrand/git/Tippy/tippy/tests/test_display_operations.py

Contains all tests for display_operations module
 
Created on Nov 24, 2011
@@ -33,7 +33,7 @@ Created on Nov 24, 2011
       

-
unittest.TestCase(__builtin__.object) +
unittest.case.TestCase(__builtin__.object)
Test @@ -44,14 +44,14 @@ Created on Nov 24, 2011
+class Test(unittest.case.TestCase)
 
-class Test(unittest.TestCase)
    This class inherits from unittest
 
 
Method resolution order:
Test
-
unittest.TestCase
+
unittest.case.TestCase
__builtin__.object

@@ -64,7 +64,7 @@ Methods defined here:
## TESTS
-Methods inherited from unittest.TestCase:
+Methods inherited from unittest.case.TestCase:
__call__(self, *args, **kwds)
__eq__(self, other)
@@ -81,58 +81,203 @@ not have a method with the specified name.
__str__(self)
-
assertAlmostEqual = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
addCleanup(self, function, *args, **kwargs)
Add a function, with arguments, to be called when the test is
+completed. Functions added are called on a LIFO basis and are
+called after tearDown on test failure or success.

+Cleanup items are called even if setUp fails (unlike tearDown).
+ +
addTypeEqualityFunc(self, typeobj, function)
Add a type specific assertEqual style function to compare a type.

+This method is for use by TestCase subclasses that need to register
+their own type equality functions to provide nicer error messages.

+Args:
+    typeobj: The data type to call this function on when both values
+            are of the same type in assertEqual().
+    function: The callable taking two arguments and an optional
+            msg= argument that raises self.failureException with a
+            useful error message when the two arguments are not equal.
+ +
assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertAlmostEquals = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
assertAlmostEquals = assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertEqual = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertDictContainsSubset(self, expected, actual, msg=None)
Checks whether actual is a superset of expected.
+ +
assertDictEqual(self, d1, d2, msg=None)
+ +
assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertEquals = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertEquals = assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertFalse = failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
assertFalse(self, expr, msg=None)
Check that the expression is false.
-
assertNotAlmostEqual = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertGreater(self, a, b, msg=None)
Just like assertTrue(a > b), but with a nicer default message.
+ +
assertGreaterEqual(self, a, b, msg=None)
Just like assertTrue(a >= b), but with a nicer default message.
+ +
assertIn(self, member, container, msg=None)
Just like assertTrue(a in b), but with a nicer default message.
+ +
assertIs(self, expr1, expr2, msg=None)
Just like assertTrue(a is b), but with a nicer default message.
+ +
assertIsInstance(self, obj, cls, msg=None)
Same as assertTrue(isinstance(obj, cls)), with a nicer
+default message.
+ +
assertIsNone(self, obj, msg=None)
Same as assertTrue(obj is None), with a nicer default message.
+ +
assertIsNot(self, expr1, expr2, msg=None)
Just like assertTrue(a is not b), but with a nicer default message.
+ +
assertIsNotNone(self, obj, msg=None)
Included for symmetry with assertIsNone.
+ +
assertItemsEqual(self, expected_seq, actual_seq, msg=None)
An unordered sequence specific comparison. It asserts that
+actual_seq and expected_seq have the same element counts.
+Equivalent to::

+    assertEqual(Counter(iter(actual_seq)),
+                     Counter(iter(expected_seq)))

+Asserts that each element has the same count in both sequences.
+Example:
+    - [0, 1, 1] and [1, 0, 1] compare equal.
+    - [0, 0, 1] and [0, 1] compare unequal.
+ +
assertLess(self, a, b, msg=None)
Just like assertTrue(a < b), but with a nicer default message.
+ +
assertLessEqual(self, a, b, msg=None)
Just like assertTrue(a <= b), but with a nicer default message.
+ +
assertListEqual(self, list1, list2, msg=None)
A list-specific equality assertion.

+Args:
+    list1: The first list to compare.
+    list2: The second list to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertMultiLineEqual(self, first, second, msg=None)
Assert that two multi-line strings are equal.
+ +
assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotAlmostEquals = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertNotAlmostEquals = assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotEqual = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertNotEquals = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEquals = assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertRaises = failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
+
assertNotIn(self, member, container, msg=None)
Just like assertTrue(a not in b), but with a nicer default message.
+ +
assertNotIsInstance(self, obj, cls, msg=None)
Included for symmetry with assertIsInstance.
+ +
assertNotRegexpMatches(self, text, unexpected_regexp, msg=None)
Fail the test if the text matches the regular expression.
+ +
assertRaises(self, excClass, callableObj=None, *args, **kwargs)
Fail unless an exception of class excClass is thrown
by callableObj when invoked with arguments args and keyword
arguments kwargs. If a different type of exception is
thrown, it will not be caught, and the test case will be
deemed to have suffered an error, exactly as for an
-unexpected exception.
+unexpected exception.

+If called with callableObj omitted or None, will return a
+context object used like this::

+     with assertRaises(SomeException):
+         do_something()

+The context manager keeps a reference to the exception as
+the 'exception' attribute. This allows you to inspect the
+exception after the assertion::

+    with assertRaises(SomeException) as cm:
+        do_something()
+    the_exception = cm.exception
+    assertEqual(the_exception.error_code, 3)
-
assertTrue = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRaisesRegexp(self, expected_exception, expected_regexp, callable_obj=None, *args, **kwargs)
Asserts that the message in a raised exception matches a regexp.

+Args:
+    expected_exception: Exception class expected to be raised.
+    expected_regexp: Regexp (re pattern object or string) expected
+            to be found in error message.
+    callable_obj: Function to be called.
+    args: Extra args.
+    kwargs: Extra kwargs.
-
assert_ = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRegexpMatches(self, text, expected_regexp, msg=None)
Fail the test unless the text matches the regular expression.
+ +
assertSequenceEqual(self, seq1, seq2, msg=None, seq_type=None)
An equality assertion for ordered sequences (like lists and tuples).

+For the purposes of this function, a valid ordered sequence type is one
+which can be indexed, has a length, and has an equality operator.

+Args:
+    seq1: The first sequence to compare.
+    seq2: The second sequence to compare.
+    seq_type: The expected datatype of the sequences, or None if no
+            datatype should be enforced.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertSetEqual(self, set1, set2, msg=None)
A set-specific equality assertion.

+Args:
+    set1: The first set to compare.
+    set2: The second set to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.

+assertSetEqual uses ducktyping to support different types of sets, and
+is optimized for sets specifically (parameters must support a
+difference method).
+ +
assertTrue(self, expr, msg=None)
Check that the expression is true.
+ +
assertTupleEqual(self, tuple1, tuple2, msg=None)
A tuple-specific equality assertion.

+Args:
+    tuple1: The first tuple to compare.
+    tuple2: The second tuple to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assert_ = assertTrue(self, expr, msg=None)
Check that the expression is true.
countTestCases(self)
@@ -140,38 +285,24 @@ unexpected exception.
defaultTestResult(self)
+
doCleanups(self)
Execute all cleanup functions. Normally called for you after
+tearDown.
+
fail(self, msg=None)
Fail immediately, with the given message.
-
failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
failIf = deprecated_func(*args, **kwargs)
-
failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failIfAlmostEqual = deprecated_func(*args, **kwargs)
-
failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
-operator.
+
failIfEqual = deprecated_func(*args, **kwargs)
-
failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
failUnless = deprecated_func(*args, **kwargs)
-
failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failUnlessAlmostEqual = deprecated_func(*args, **kwargs)
-
failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
-operator.
+
failUnlessEqual = deprecated_func(*args, **kwargs)
-
failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
-by callableObj when invoked with arguments args and keyword
-arguments kwargs. If a different type of exception is
-thrown, it will not be caught, and the test case will be
-deemed to have suffered an error, exactly as for an
-unexpected exception.
+
failUnlessRaises = deprecated_func(*args, **kwargs)
id(self)
@@ -183,8 +314,16 @@ description has been provided.
The default implementation of this method returns the first line of
the specified test method's docstring.
+
skipTest(self, reason)
Skip this test.
+
-Data descriptors inherited from unittest.TestCase:
+Class methods inherited from unittest.case.TestCase:
+
setUpClass(cls) from __builtin__.type
Hook method for setting up class fixture before running tests in the class.
+ +
tearDownClass(cls) from __builtin__.type
Hook method for deconstructing the class fixture after running all tests in the class.
+ +
+Data descriptors inherited from unittest.case.TestCase:
__dict__
dictionary for instance variables (if defined)
@@ -192,8 +331,12 @@ Data descriptors inherited from unittest.TestCa
list of weak references to the object (if defined)

-Data and other attributes inherited from
unittest.TestCase:
+Data and other attributes inherited from unittest.case.TestCase:
failureException = <type 'exceptions.AssertionError'>
Assertion failed.
+
longMessage = False
+ +
maxDiff = 640
+
\ No newline at end of file diff --git a/doc/tippy.tests.test_segmentation.html b/doc/tippy.tests.test_segmentation.html index f686051..34a18ac 100644 --- a/doc/tippy.tests.test_segmentation.html +++ b/doc/tippy.tests.test_segmentation.html @@ -8,7 +8,7 @@  
 
tippy.tests.test_segmentation
index
/home/airballman/documents/workspace/Tippy/tippy/tests/test_segmentation.py
+>index
/home/jlengrand/git/Tippy/tippy/tests/test_segmentation.py

"
Created on Nov 26, 2011
 
@@ -32,7 +32,7 @@ Created on Nov 26, 2011
       

-
unittest.TestCase(__builtin__.object) +
unittest.case.TestCase(__builtin__.object)
Test @@ -43,12 +43,12 @@ Created on Nov 26, 2011
+class Test(unittest.case.TestCase)
 
-class Test(unittest.TestCase)
    
Method resolution order:
Test
-
unittest.TestCase
+
unittest.case.TestCase
__builtin__.object

@@ -61,7 +61,7 @@ Methods defined here:
## TESTS
-Methods inherited from unittest.TestCase:
+Methods inherited from unittest.case.TestCase:
__call__(self, *args, **kwds)
__eq__(self, other)
@@ -78,58 +78,203 @@ not have a method with the specified name.
__str__(self)
-
assertAlmostEqual = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
addCleanup(self, function, *args, **kwargs)
Add a function, with arguments, to be called when the test is
+completed. Functions added are called on a LIFO basis and are
+called after tearDown on test failure or success.

+Cleanup items are called even if setUp fails (unlike tearDown).
+ +
addTypeEqualityFunc(self, typeobj, function)
Add a type specific assertEqual style function to compare a type.

+This method is for use by TestCase subclasses that need to register
+their own type equality functions to provide nicer error messages.

+Args:
+    typeobj: The data type to call this function on when both values
+            are of the same type in assertEqual().
+    function: The callable taking two arguments and an optional
+            msg= argument that raises self.failureException with a
+            useful error message when the two arguments are not equal.
+ +
assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertAlmostEquals = failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
+
assertAlmostEquals = assertAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are unequal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is more than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+If the two objects compare equal then they will automatically
+compare almost equal.
-
assertEqual = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertDictContainsSubset(self, expected, actual, msg=None)
Checks whether actual is a superset of expected.
+ +
assertDictEqual(self, d1, d2, msg=None)
+ +
assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertEquals = failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
+
assertEquals = assertEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
operator.
-
assertFalse = failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
assertFalse(self, expr, msg=None)
Check that the expression is false.
-
assertNotAlmostEqual = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertGreater(self, a, b, msg=None)
Just like assertTrue(a > b), but with a nicer default message.
+ +
assertGreaterEqual(self, a, b, msg=None)
Just like assertTrue(a >= b), but with a nicer default message.
+ +
assertIn(self, member, container, msg=None)
Just like assertTrue(a in b), but with a nicer default message.
+ +
assertIs(self, expr1, expr2, msg=None)
Just like assertTrue(a is b), but with a nicer default message.
+ +
assertIsInstance(self, obj, cls, msg=None)
Same as assertTrue(isinstance(obj, cls)), with a nicer
+default message.
+ +
assertIsNone(self, obj, msg=None)
Same as assertTrue(obj is None), with a nicer default message.
+ +
assertIsNot(self, expr1, expr2, msg=None)
Just like assertTrue(a is not b), but with a nicer default message.
+ +
assertIsNotNone(self, obj, msg=None)
Included for symmetry with assertIsNone.
+ +
assertItemsEqual(self, expected_seq, actual_seq, msg=None)
An unordered sequence specific comparison. It asserts that
+actual_seq and expected_seq have the same element counts.
+Equivalent to::

+    assertEqual(Counter(iter(actual_seq)),
+                     Counter(iter(expected_seq)))

+Asserts that each element has the same count in both sequences.
+Example:
+    - [0, 1, 1] and [1, 0, 1] compare equal.
+    - [0, 0, 1] and [0, 1] compare unequal.
+ +
assertLess(self, a, b, msg=None)
Just like assertTrue(a < b), but with a nicer default message.
+ +
assertLessEqual(self, a, b, msg=None)
Just like assertTrue(a <= b), but with a nicer default message.
+ +
assertListEqual(self, list1, list2, msg=None)
A list-specific equality assertion.

+Args:
+    list1: The first list to compare.
+    list2: The second list to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertMultiLineEqual(self, first, second, msg=None)
Assert that two multi-line strings are equal.
+ +
assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotAlmostEquals = failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
+
assertNotAlmostEquals = assertNotAlmostEqual(self, first, second, places=None, msg=None, delta=None)
Fail if the two objects are equal as determined by their
difference rounded to the given number of decimal places
-(default 7) and comparing to zero.
+(default 7) and comparing to zero, or by comparing that the
+between the two objects is less than the given delta.
 
Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+as significant digits (measured from the most signficant digit).

+Objects that are equal automatically fail.
-
assertNotEqual = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertNotEquals = failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
+
assertNotEquals = assertNotEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
operator.
-
assertRaises = failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
+
assertNotIn(self, member, container, msg=None)
Just like assertTrue(a not in b), but with a nicer default message.
+ +
assertNotIsInstance(self, obj, cls, msg=None)
Included for symmetry with assertIsInstance.
+ +
assertNotRegexpMatches(self, text, unexpected_regexp, msg=None)
Fail the test if the text matches the regular expression.
+ +
assertRaises(self, excClass, callableObj=None, *args, **kwargs)
Fail unless an exception of class excClass is thrown
by callableObj when invoked with arguments args and keyword
arguments kwargs. If a different type of exception is
thrown, it will not be caught, and the test case will be
deemed to have suffered an error, exactly as for an
-unexpected exception.
+unexpected exception.

+If called with callableObj omitted or None, will return a
+context object used like this::

+     with assertRaises(SomeException):
+         do_something()

+The context manager keeps a reference to the exception as
+the 'exception' attribute. This allows you to inspect the
+exception after the assertion::

+    with assertRaises(SomeException) as cm:
+        do_something()
+    the_exception = cm.exception
+    assertEqual(the_exception.error_code, 3)
-
assertTrue = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRaisesRegexp(self, expected_exception, expected_regexp, callable_obj=None, *args, **kwargs)
Asserts that the message in a raised exception matches a regexp.

+Args:
+    expected_exception: Exception class expected to be raised.
+    expected_regexp: Regexp (re pattern object or string) expected
+            to be found in error message.
+    callable_obj: Function to be called.
+    args: Extra args.
+    kwargs: Extra kwargs.
-
assert_ = failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
assertRegexpMatches(self, text, expected_regexp, msg=None)
Fail the test unless the text matches the regular expression.
+ +
assertSequenceEqual(self, seq1, seq2, msg=None, seq_type=None)
An equality assertion for ordered sequences (like lists and tuples).

+For the purposes of this function, a valid ordered sequence type is one
+which can be indexed, has a length, and has an equality operator.

+Args:
+    seq1: The first sequence to compare.
+    seq2: The second sequence to compare.
+    seq_type: The expected datatype of the sequences, or None if no
+            datatype should be enforced.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assertSetEqual(self, set1, set2, msg=None)
A set-specific equality assertion.

+Args:
+    set1: The first set to compare.
+    set2: The second set to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.

+assertSetEqual uses ducktyping to support different types of sets, and
+is optimized for sets specifically (parameters must support a
+difference method).
+ +
assertTrue(self, expr, msg=None)
Check that the expression is true.
+ +
assertTupleEqual(self, tuple1, tuple2, msg=None)
A tuple-specific equality assertion.

+Args:
+    tuple1: The first tuple to compare.
+    tuple2: The second tuple to compare.
+    msg: Optional message to use on failure instead of a list of
+            differences.
+ +
assert_ = assertTrue(self, expr, msg=None)
Check that the expression is true.
countTestCases(self)
@@ -137,38 +282,24 @@ unexpected exception.
defaultTestResult(self)
+
doCleanups(self)
Execute all cleanup functions. Normally called for you after
+tearDown.
+
fail(self, msg=None)
Fail immediately, with the given message.
-
failIf(self, expr, msg=None)
Fail the test if the expression is true.
+
failIf = deprecated_func(*args, **kwargs)
-
failIfAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are equal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failIfAlmostEqual = deprecated_func(*args, **kwargs)
-
failIfEqual(self, first, second, msg=None)
Fail if the two objects are equal as determined by the '=='
-operator.
+
failIfEqual = deprecated_func(*args, **kwargs)
-
failUnless(self, expr, msg=None)
Fail the test unless the expression is true.
+
failUnless = deprecated_func(*args, **kwargs)
-
failUnlessAlmostEqual(self, first, second, places=7, msg=None)
Fail if the two objects are unequal as determined by their
-difference rounded to the given number of decimal places
-(default 7) and comparing to zero.

-Note that decimal places (from zero) are usually not the same
-as significant digits (measured from the most signficant digit).
+
failUnlessAlmostEqual = deprecated_func(*args, **kwargs)
-
failUnlessEqual(self, first, second, msg=None)
Fail if the two objects are unequal as determined by the '=='
-operator.
+
failUnlessEqual = deprecated_func(*args, **kwargs)
-
failUnlessRaises(self, excClass, callableObj, *args, **kwargs)
Fail unless an exception of class excClass is thrown
-by callableObj when invoked with arguments args and keyword
-arguments kwargs. If a different type of exception is
-thrown, it will not be caught, and the test case will be
-deemed to have suffered an error, exactly as for an
-unexpected exception.
+
failUnlessRaises = deprecated_func(*args, **kwargs)
id(self)
@@ -180,8 +311,16 @@ description has been provided.
The default implementation of this method returns the first line of
the specified test method's docstring.
+
skipTest(self, reason)
Skip this test.
+
-Data descriptors inherited from unittest.TestCase:
+Class methods inherited from unittest.case.TestCase:
+
setUpClass(cls) from __builtin__.type
Hook method for setting up class fixture before running tests in the class.
+ +
tearDownClass(cls) from __builtin__.type
Hook method for deconstructing the class fixture after running all tests in the class.
+ +
+Data descriptors inherited from unittest.case.TestCase:
__dict__
dictionary for instance variables (if defined)
@@ -189,8 +328,12 @@ Data descriptors inherited from unittest.TestCa
list of weak references to the object (if defined)

-Data and other attributes inherited from
unittest.TestCase:
+Data and other attributes inherited from unittest.case.TestCase:
failureException = <type 'exceptions.AssertionError'>
Assertion failed.
+
longMessage = False
+ +
maxDiff = 640
+
\ No newline at end of file diff --git a/examples/region_growing.py b/examples/region_growing.py index f8b24ce..0a8fa17 100644 --- a/examples/region_growing.py +++ b/examples/region_growing.py @@ -28,7 +28,7 @@ import tippy.display_operations as do user_input = 0 -img_name = "data/gnu.jpg" +img_name = "tippy/data/gnu.jpg" threshold = 20 connectivity = 8 img = cv.LoadImage(img_name, cv.CV_LOAD_IMAGE_GRAYSCALE)