Ejemplo n.º 1
0
 def test_no_other(self) : 
     """omit "other" land classification types"""
     v = [ 1, 4, 6,7 ] 
     expected = [0,2,4,4]
     result = ba.landcover_classification(v)
     self.assertTrue(np.all( expected==result))
Ejemplo n.º 2
0
 def test_basic(self) : 
     """ not too hard """
     v = [ 1, 4, 6,7, 11, 16 ] 
     expected = [0, 2, 4, 6]
     result = ba.landcover_classification(v)
     self.assertTrue(np.all( expected==result))
Ejemplo n.º 3
0
 def test_no_nonforest(self) : 
     """omit nonforested landcover types"""
     v = [ 1, 4, 11, 16 ] 
     expected = [0,2,2,4]
     result = ba.landcover_classification(v)
     self.assertTrue(np.all( expected==result))