def test_single_train_iter(self):
     single_train_iter(
         self,
         self.scenario,
         debug=False,
         args=AdditionalTrainerArgs(input_gradient_regularization=True,
                                    preload_data=True),
     )
示例#2
0
    def test_single_train_iter(self):
        # single_train_iter(self, self.get_scenario_parallel(), debug=False)

        import signal

        t1 = time.time()
        single_train_iter(self, self.get_scenario_none_parallel(), debug=False)
        none_paralle_time = time.time() - t1

        import math

        def handler(signum, frame):
            print("Timeout reached!")
            raise TimeoutError(
                "Parallel inputpipeline took at least twice as long as the none parallel version. It's probably stuckt!"
            )

        print(
            f"### Parallel input test timeout: {int(math.ceil(none_paralle_time * 2))} ######"
        )
        signal.signal(signal.SIGALRM, handler)
        signal.alarm(int(math.ceil(none_paralle_time * 2)))
        single_train_iter(self, self.get_scenario_parallel(), debug=False)
        signal.alarm(0)
示例#3
0
 def test_single_train_iter(self):
     single_train_iter(self,
                       self.get_scenario(),
                       debug=False,
                       lav_every_n=0)
示例#4
0
 def test_single_train_iter(self):
     single_train_iter(self, self.get_scenario(), debug=False)
示例#5
0
 def test_single_train_iter_debug(self):
     single_train_iter(self, TutorialScenarioTest, debug=True)
示例#6
0
 def test_single_train_iter(self):
     single_train_iter(self, TutorialScenarioTest, debug=False)
示例#7
0
 def test_single_train_iter(self):
     single_train_iter(
         self,
         TutorialScenarioTest,
         debug=False,
         args=AdditionalTrainerArgs(input_gradient_regularization=True))
示例#8
0
 def test_single_train_iter(self):
     single_train_iter(self, TemplateScenario)