test_server.py
def start_experiments(self, exp_data):
        """Start a set of experiments.

        :param exp_data: Dict containing parameters for the experiments.
        """
        self._logger.info("Starting experiment.")

        self._logger.info("Killing any existing evaluation processes "
                          "on testbed hosts.")
        playbook_cmd = self._ANS_PLYBK + "kill_processes.yaml"
        os.system(playbook_cmd)

        self._logger.info("Copying files to the controller and DPAE.")
        playbook_cmd = (self._ANS_PLYBK + "copy_config_policy.yaml "
                                         "--extra-vars "
                                         "\"contr_config={0} "
                                         "contr_main_policy={1} "
                                         "dpae_dataset={2}\"".format(
            exp_data["contr_config"], exp_data["contr_main_policy"], 
            exp_data["dpae_dataset"]))
        os.system(playbook_cmd)

        self._logger.info("Starting controller application.")
        playbook_cmd = self._ANS_PLYBK + "start_controller.yaml"
        os.system(playbook_cmd)

        self._logger.info("Starting DPAE application.")
        playbook_cmd = (self._ANS_PLYBK + "start_dpae.yaml "
                       "--extra-vars \"mosp_outfile={0}\"".format(
                           exp_data["mosp_outfile"]))
        os.system(playbook_cmd)

        self._logger.info("Waiting for DPAE notification...")
        server = DPAEHandler(self._log_file)
        result = server.handle(self._HOST, self._PORT)
        if not result:
            self._logger.critical("DPAE classifier training completion "
                                  "notification failed. Exiting...")
            sys.exit(1)

        self._logger.info("Starting traffic replay.")
        playbook_cmd = self._ANS_PLYBK + "start_replay.yaml"
        os.system(playbook_cmd)

        self._logger.info("Killing all running evaluation processes "
                          "on testbed hosts.")
        playbook_cmd = self._ANS_PLYBK + "kill_processes.yaml"
        os.system(playbook_cmd)

        self._logger.info("Test server shutting down...")
Start a set of experiments.

        :param exp_data: Dict containing parameters for the experiments.
        
Start a set of experiments.
Start a set of experiments .
def start_experiments(self, exp_data):
        self._logger.info("Starting experiment.")
        self._logger.info("Killing any existing evaluation processes "
                          "on testbed hosts.")
        playbook_cmd = self._ANS_PLYBK + "kill_processes.yaml"
        os.system(playbook_cmd)
        self._logger.info("Copying files to the controller and DPAE.")
        playbook_cmd = (self._ANS_PLYBK + "copy_config_policy.yaml "
                                         "--extra-vars "
                                         "\"contr_config={0} "
                                         "contr_main_policy={1} "
                                         "dpae_dataset={2}\"".format(
            exp_data["contr_config"], exp_data["contr_main_policy"], 
            exp_data["dpae_dataset"]))
        os.system(playbook_cmd)
        self._logger.info("Starting controller application.")
        playbook_cmd = self._ANS_PLYBK + "start_controller.yaml"
        os.system(playbook_cmd)
        self._logger.info("Starting DPAE application.")
        playbook_cmd = (self._ANS_PLYBK + "start_dpae.yaml "
                       "--extra-vars \"mosp_outfile={0}\"".format(
                           exp_data["mosp_outfile"]))
        os.system(playbook_cmd)
        self._logger.info("Waiting for DPAE notification...")
        server = DPAEHandler(self._log_file)
        result = server.handle(self._HOST, self._PORT)
        if not result:
            self._logger.critical("DPAE classifier training completion "
                                  "notification failed. Exiting...")
            sys.exit(1)
        self._logger.info("Starting traffic replay.")
        playbook_cmd = self._ANS_PLYBK + "start_replay.yaml"
        os.system(playbook_cmd)
        self._logger.info("Killing all running evaluation processes "
                          "on testbed hosts.")
        playbook_cmd = self._ANS_PLYBK + "kill_processes.yaml"
        os.system(playbook_cmd)
        self._logger.info("Test server shutting down...")
def start_experiments ( self , exp_data ) : self . _logger . info ( "Starting experiment." ) self . _logger . info ( "Killing any existing evaluation processes " "on testbed hosts." ) playbook_cmd = self . _ANS_PLYBK + "kill_processes.yaml" os . system ( playbook_cmd ) self . _logger . info ( "Copying files to the controller and DPAE." ) playbook_cmd = ( self . _ANS_PLYBK + "copy_config_policy.yaml " "--extra-vars " "\"contr_config={0} " "contr_main_policy={1} " "dpae_dataset={2}\"" . format ( exp_data [ "contr_config" ] , exp_data [ "contr_main_policy" ] , exp_data [ "dpae_dataset" ] ) ) os . system ( playbook_cmd ) self . _logger . info ( "Starting controller application." ) playbook_cmd = self . _ANS_PLYBK + "start_controller.yaml" os . system ( playbook_cmd ) self . _logger . info ( "Starting DPAE application." ) playbook_cmd = ( self . _ANS_PLYBK + "start_dpae.yaml " "--extra-vars \"mosp_outfile={0}\"" . format ( exp_data [ "mosp_outfile" ] ) ) os . system ( playbook_cmd ) self . _logger . info ( "Waiting for DPAE notification..." ) server = DPAEHandler ( self . _log_file ) result = server . handle ( self . _HOST , self . _PORT ) if not result : self . _logger . critical ( "DPAE classifier training completion " "notification failed. Exiting..." ) sys . exit ( 1 ) self . _logger . info ( "Starting traffic replay." ) playbook_cmd = self . _ANS_PLYBK + "start_replay.yaml" os . system ( playbook_cmd ) self . _logger . info ( "Killing all running evaluation processes " "on testbed hosts." ) playbook_cmd = self . _ANS_PLYBK + "kill_processes.yaml" os . system ( playbook_cmd ) self . _logger . info ( "Test server shutting down..." )
Start a set of experiments.
Start a set of experiments .
"""Start a set of experiments.

        :param exp_data: Dict containing parameters for the experiments.
        """
self
exp_data
Dict containing parameters for the experiments.
Dict containing parameters for the experiments .