Exemplo n.º 1
0
    def addAccFeat(self, acc, index, value):
        if index == 0:
            bal = self.balanceCache.get(acc, 0)
            bal += value
            self.balanceCache[acc] = bal

            cppBalanceLastSeen.setInt(acc, index, bal // self.balanceCutoff,
                                      False, False,
                                      False)  #convert to ETH and pass to C++
        else:  #TODO this is an impossible case, but still implement it
            raise NotImplementedError
Exemplo n.º 2
0
 def setAccFeat(self, acc, index, value):
     if index == 1:  #lastSeen feature
         cppBalanceLastSeen.setInt(acc, index, value, False, False, False)
     else:  #TODO this is an impossible case, but still implement it
         raise NotImplementedError