Return a string to run OrfM with, assuming sequences are incoming on
        stdin and printed to stdout
        
        Parameters
        ----------
        input_path: str
            path to the input path, or None for STDIN being the input
187399
def command_line(self, input_path=None):
        '''
        '''
        
        if self.min_orf_length:
            orfm_arg_l = " -m %d" % self.min_orf_length
        else:
            orfm_arg_l = ''
        
        if self.restrict_read_length:
            orfm_arg_l = " -l %d" % self.restrict_read_length
            
        cmd = 'orfm %s ' % orfm_arg_l
        if input_path:
            cmd += input_path
        logging.debug("OrfM command chunk: %s" % cmd)
        return cmd
413217
def runpath(path, argv, filename=None, threads=True, verbose=False):
    
    _run(threads, verbose, 'runpath', filename, path, argv)
16713
def set_input_path(input_job)
      job_name = input_job.job_name
      input_filter = job_config['input_filter']

      s3_path = "/data/1-parse/#{job_name}/segments/*/#{input_filter}"
      build_s3_uri(s3_path)
    end
784442
def _input_as_multiline_string(self, data):
        
        self._input_filename = self.getTmpFilename(
            self.WorkingDir, suffix='.fasta')
        with open(self._input_filename, 'w') as f:
            f.write(data)
        return self._input_filename
272703
def standard_input():
    """"""
    with click.get_text_stream("stdin") as stdin:
        while stdin.readable():
            line = stdin.readline()
            if line:
                yield line.strip().encode("utf-8")
88098
def check_file_encoding(self, input_file_path):
        
        self.log([u"Checking encoding of file '%s'", input_file_path])
        self.result = ValidatorResult()
        if self._are_safety_checks_disabled(u"check_file_encoding"):
            return self.result
        if not gf.file_can_be_read(input_file_path):
            self._failed(u"File '%s' cannot be read." % (input_file_path))
            return self.result
        with io.open(input_file_path, "rb") as file_object:
            bstring = file_object.read()
            self._check_utf8_encoding(bstring)
        return self.result
556694
def _input_file_as_lines(cls, session: AppSession):
        ''''''
        if session.args.input_file == sys.stdin:
            input_file = session.args.input_file
        else:
            reader = codecs.getreader(session.args.local_encoding or 'utf-8')
            input_file = reader(session.args.input_file)

        return input_file
1303740
def convert_to_str(input_string):

    

    if sys.version < '3':

        if isinstance(input_string, str) \
                or isinstance(input_string, unicode):  # pragma: no cover py3

            return input_string  # pragma: no cover py3

    else:

        if isinstance(input_string, str):  # pragma: no cover py3

            return input_string  # pragma: no cover py3

    return str(input_string)
63336
def print_input_output(opts):
    
    if opts.is_dir:
        print("Root input directory:\t" + opts.input)
        print("Outputting to:\t\t" + opts.output + "\n")
    else:
        print("Input file:\t\t" + opts.input)
        print("Outputting to:\t\t" + opts.output + opts.input + "\n")
145116
def get_input(input_func, input_str):
    
    val = input_func("Please enter your {0}: ".format(input_str))
    while not val or not len(val.strip()):
        val = input_func("You didn't enter a valid {0}, please try again: ".format(input_str))
    return val
1270583
def read_input(self, input_cls, filename, **kwargs):
        
        input_inst = input_cls()
        input_inst.read_input(filename)
        return input_inst.get_data()
402496
def run(input, conf, filepath=None):
    
    if conf.is_file_ignored(filepath):
        return ()

    if isinstance(input, (type(b''), type(u''))):  # compat with Python 2 & 3
        return _run(input, conf, filepath)
    elif hasattr(input, 'read'):  # Python 2's file or Python 3's io.IOBase
        # We need to have everything in memory to parse correctly
        content = input.read()
        return _run(content, conf, filepath)
    else:
        raise TypeError('input should be a string or a stream')
602078
def prompt_stdin(prompt):
    """"""
    # raw_input returns the empty string for "enter"
    yes = set(['yes', 'y'])
    no = set(['no','n'])

    try:
        print(prompt)
        if sys.version_info>=(3,0):
            choice = input().lower()
        else:
            choice = raw_input().lower()
        # would like to test for which exceptions here
    except:
        print('Stdin is not implemented.')
        print('You need to set')
        print('overide_manual_authorize=True')
        print('to proceed with the download. Please set that variable and continue.')
        raise


    if choice in yes:
        return True
    elif choice in no:
        return False
    else:
        print("Your response was a " + choice)
        print("Please respond with 'yes', 'y' or 'no', 'n'")
785474
def _stdin_(p):
    """"""
    _v = sys.version[0]
    return input(p) if _v is '3' else raw_input(p)
698651
def input_file(self):
        
        return path.join(path.dirname(__file__), 'data', 'tgs{:s}.tsv'.format(self.number))
29828
def _input_as_multiline_string(self, data):
        
        filename = self._input_filename = \
            FilePath(self.getTmpFilename(self.TmpDir))
        data_file = open(filename, 'w')
        data_file.write(data)
        data_file.close()
        return filename
448337
def _read(path):
    
    input = open(path, "r", encoding="utf-8")
    try:
        return input.read()
    finally:
        input.close()