#NEWLINE# def _move_zeros_to_the_end( ntf_z , inband_zeros ) : #NEWLINE# #INDENT# 'RealizeQNTF requires the imageband zeros to be put at the end\n    of the list of zeros.\n\n    This function ensures exactly that.\n    ' #NEWLINE# to_the_end = [ i for ( i , iz ) in enumerate ( inband_zeros ) if ( not iz ) ] #NEWLINE# for ( i , orig ) in enumerate ( to_the_end ) : #NEWLINE# #INDENT# ntf_z = np . append ( ntf_z , ntf_z [ ( orig - i ) ] ) #NEWLINE# ntf_z = np . delete ( ntf_z , ( orig - i ) ) #NEWLINE# inband_zeros = np . append ( inband_zeros , inband_zeros [ ( orig - i ) ] ) #NEWLINE# inband_zeros = np . delete ( orig , ( orig - i ) ) #NEWLINE# #UNINDENT# return ( ntf_z , inband_zeros )