def npz_to_W_pdf(path=None, regx='w1pre_[0-9]+\\.(npz)'):
 file_list = load_file_list(path=path, regx=regx)
 for f in file_list:
  W = load_npz(path, f)[0]
  print ('%s --> %s' % (f, (f.split('.')[0] + '.pdf')))
  visualize.W(W, second=10, saveable=True, name=f.split('.')[0], fig_idx=2012)

def npz_to_W_pdf ( path = None , regx = 'w1pre_[0-9]+\\.(npz)' ) : file_list = load_file_list ( path = path , regx = regx ) for f in file_list : W = load_npz ( path , f ) [ 0 ] print ( '%s --> %s' % ( f , ( f . split ( '.' ) [ 0 ] + '.pdf' ) ) ) visualize . W ( W , second = 10 , saveable = True , name = f . split ( '.' ) [ 0 ] , fig_idx = 2012 )
convert the first weight matrix of .