Beispiel #1
0
    def test_run_tspf_line_all_infos(self):

        [df_all_line_infos] = run_tspf(
            self.distSys, tools=[lines.get_all_infos], num_steps=288
        )

        try:
            assert_frame_equal(
                self.all_line_infos,
                df_all_line_infos,
                check_dtype=False,
                check_less_precise=4,
            )
        except AssertionError as err:
            raise err
Beispiel #2
0
    def test_run_tspf_v_pu(self):

        [df_all_v_pu_ang] = run_tspf(
            self.distSys, tools=[voltages.get_all], num_steps=288
        )

        try:
            assert_frame_equal(
                self.all_v_pu_ang,
                df_all_v_pu_ang,
                check_dtype=False,
                check_less_precise=4,
            )
        except AssertionError as err:
            raise err
Beispiel #3
0
    def test_buil_dataset_tspf_all_taps_number(self):

        [df_all_taps_number] = run_tspf(
            self.distSys, tools=[regs.get_all_taps_number], num_steps=288
        )

        try:
            assert_frame_equal(
                self.reg_number,
                df_all_taps_number,
                check_dtype=False,
                check_less_precise=4,
            )
        except AssertionError as err:
            raise err
Beispiel #4
0
    def test_get_bus_v_pu_ang(self):
        def get_one(distSys):
            return voltages.get_from_buses(distSys, self.bus_names)

        [df_v_pu_ang] = run_tspf(self.distSys, tools=[get_one], num_steps=288)

        try:
            assert_frame_equal(
                self.all_v_pu_ang.reset_index(drop=True),
                df_v_pu_ang.reset_index(drop=True),
                check_dtype=False,
                check_less_precise=4,
            )

        except AssertionError as err:
            raise err
Beispiel #5
0
    def test_run_tspf_taps_number(self):
        def get_one(distSys):
            return regs.get_tap_number(distSys, self.reg_names)

        [df_all_taps_number] = run_tspf(
            self.distSys, tools=[get_one], num_steps=288
        )

        try:
            assert_frame_equal(
                self.reg_number,
                df_all_taps_number,
                check_dtype=False,
                check_less_precise=4,
            )
        except AssertionError as err:
            raise err
Beispiel #6
0
    def test_run_tspf_line_infos(self):
        def get_one(distSys):
            return lines.get_infos(distSys, self.line_names)

        [df_all_line_infos] = run_tspf(
            self.distSys, tools=[get_one], num_steps=288,
        )

        try:
            assert_frame_equal(
                self.all_line_infos.reset_index(drop=True),
                df_all_line_infos.reset_index(drop=True),
                check_dtype=False,
                check_less_precise=4,
            )

        except AssertionError as err:
            raise err