| [mmis] [Up] [mmisequal] | Relations |
mmisbinary returns
TRUE(1) if the datatype of the input image is binary. A binary image has just the values 0 and 1.
>>> a=uint8([0, 1, 0, 1])
>>> print mmisbinary(a)
0.0
>>> b=(a)
>>> print mmisbinary(b)
0.0
def mmisbinary(f):
bool = type(f) is type(mmbinary([1]))
if bool:
bool = f.typecode() == '1'
return bool
| [mmis] [Up] [mmisequal] | |
| Copyright (c) 2003, Roberto A. Lotufo, UNICAMP-University of Campinas; Rubens C. Machado, CenPRA-Renato Archer Research Center. |