<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def process_arguments(arguments):
 """Recompute special cases for input arguments."""

    Settings.update(arguments)

    Settings.config_program_reqs(PROGRAMS)

    Settings.verbose = arguments.verbose + 1
    Settings.paths = set(arguments.paths)

    if arguments.formats == DEFAULT_FORMATS:
        Settings.formats = arguments.to_png_formats | \
            jpeg.FORMATS | gif.FORMATS
    else:
        Settings.formats = set(
            arguments.formats.upper().split(FORMAT_DELIMETER))

    if arguments.comics:
        Settings.formats = Settings.formats | comic.FORMATS

    if arguments.optimize_after is not None:
        try:
            after_dt = dateutil.parser.parse(arguments.optimize_after)
            arguments.optimize_after = time.mktime(after_dt.timetuple())
        except Exception as ex:
            print(ex)
            print('Could not parse date to optimize after.')
            exit(1)

    if arguments.jobs < 1:
        Settings.jobs = 1

    # Make a rough guess about weather or not to invoke multithreding
    # jpegrescan '-t' uses three threads
    # one off multithread switch bcaseu this is the only one right now
    files_in_paths = 0
    non_file_in_paths = False
    for filename in arguments.paths:
        if os.path.isfile(filename):
            files_in_paths += 1
        else:
            non_file_in_paths = True
    Settings.jpegrescan_multithread = not non_file_in_paths and \
        Settings.jobs - (files_in_paths*3) > -1

    return arguments