"""
Copyright (C) 2019 NVIDIA Corporation.  All rights reserved.
Licensed under the CC BY-NC-SA 4.0 license (https://creativecommons.org/licenses/by-nc-sa/4.0/legalcode).
"""

from .base_options import BaseOptions


class TestOptions(BaseOptions):
    def initialize(self, parser):
        BaseOptions.initialize(self, parser)
        parser.add_argument(
            '--results_dir', type=str, default='./results/', help='saves results here.'
        )
        parser.add_argument(
            '--which_epoch',
            type=str,
            default='latest',
            help='which epoch to load? set to latest to use latest cached model',
        )
        parser.add_argument(
            '--num_test',
            type=int,
            default=float("inf"),
            help='how many test images to run',
        )
        parser.set_defaults(
            preprocess_mode='fixed',
            crop_size=512,
            load_size=512,
            display_winsize=512,
        )
        parser.set_defaults(serial_batches=True)
        parser.set_defaults(no_flip=True)
        parser.set_defaults(no_flip_vert=True)
        parser.set_defaults(no_rotate=True)
        parser.set_defaults(phase='test')
        self.isTrain = False
        return parser
