Exemplo n.º 1
0
    def test_sum_axis1(self):
        target = np.zeros(50)
        source = np.random.rand(200).reshape(50, 4)
        b = np.sum(source, axis=1)

        sum_axis1(target, source, 1)
        self.assertEqual((b - target).max(), 0, 'Sum Axis 1 failed')
Exemplo n.º 2
0
    def total_flows(self) -> None:
        """ Totals all link flows for this class into a single link load

        Results are placed into *total_link_loads* class member
        """
        sum_axis1(self.total_link_loads, self.link_loads, self.cores)
Exemplo n.º 3
0
 def total_flows(self):
     """ Totals all link flows for this class into a single link load"""
     sum_axis1(self.total_link_loads, self.link_loads, self.cores)