def _make_ctf_name(directory, extra, raise_error=True):
 fname = op.join(directory, ((op.basename(directory)[:(-3)] + '.') + extra))
 if (not op.isfile(fname)):
  if raise_error:
   raise IOError(('Standard file %s not found' % fname))
  else:
   return None
 return fname

def _make_ctf_name ( directory , extra , raise_error = True ) : fname = op . join ( directory , ( ( op . basename ( directory ) [ : ( - 3 ) ] + '.' ) + extra ) ) if ( not op . isfile ( fname ) ) : if raise_error : raise IOError ( ( 'Standard file %s not found' % fname ) ) else : return None return fname
make a ctf name .