示例#1
0
    def plant_generate(self, table_to_plant=False, bombeo=0):
        """Set plant.
        """
        tabla = self.rtab.tables['_Plan']
        tabla2 = list(tabla)
        print(tabla2)

        if table_to_plant:
            self.plant = Plant.Plant(self.rtab.polyline, tabla,
                                     table_to_plan=True, bombeo=bombeo)
            self.rtab.tables['first'].rewrite_obj(
                self.plant.polygon, self.rtab.tables['first'].rows[0])
        else:
            self.plant = Plant.Plant(self.rtab.polyline, tabla,
                                     table_to_plan=False, bombeo=bombeo)
            tabla.update_plan_dists(self.plant)
示例#2
0
    def _mode_exact(self, index):
        """Return"""
        polyg = self._polyg_parall(self.dist[index])
        table = self._table_parall(self.dist[index])

        plantalignd = Plant.Plant(polyg, table)
        d_alings = []
        pnts_limits = self._get_limits_plant(plantalignd)

        for j, r_pnt in enumerate(pnts_limits):
            if self.pks[index] <= r_pnt.npk <= self.pks[index + 1]:
                self.list_lim.append(r_pnt.npk)
                self.elev_lim.append(self.elev[index])
                d_alings.append(plantalignd[j])

        return d_alings