code: def calculate_fee(self, input_values):
          '''
          SaplingTx, list(int) -> int
          '''
          total_in = sum(input_values)
          total_out = sum([utils.le2i(tx_out.value) for tx_out in self.tx_outs])
          shileded_net = utils.le2i(self.value_balance, signed=True)
          for js in self.tx_joinsplits:
              total_in += utils.le2i(js.vpub_new)
              total_out += utils.le2i(js.vpub_old)
          return total_in - total_out + shileded_nef calculate_fee(self, input_values):
          '''
          SaplingTx, list(int) -> int
          '''
          total_in = sum(input_values)
          total_out = sum([utils.le2i(tx_out.value) for tx_out in self.tx_outs])
          shileded_net = utils.le2i(self.value_balance, signed=True)
          for js in self.tx_joinsplits:
              total_in += utils.le2i(js.vpub_new)
              total_out += utils.le2i(js.vpub_old)
          return total_in - total_out + shileded_net
docs: SaplingTx, list(int) -> int