#NEWLINE# @ staticmethod #NEWLINE# def adaptive_threshold( filename_in , filename_out ) : #NEWLINE# #INDENT# img = imread ( filename_in , as_grey = True ) #NEWLINE# binary_adaptive = threshold_adaptive ( img , 40 , offset = 10 ) #NEWLINE# plt . imsave ( filename_out , filename_in , cmap = plt . cm . gray )