'Convert `from_amount` from currency `self` to `to_currency`.'

@api.multi
def compute(self, from_amount, to_currency, round=True):

    (self, to_currency) = ((self or to_currency), (to_currency or self))
    assert self, 'compute    from    unknown    currency'
    assert to_currency, 'compute    to    unknown    currency'
    if (self == to_currency):
        to_amount = from_amount
    else:
        to_amount = (from_amount * self._get_conversion_rate(self, to_currency))
    return (to_currency.round(to_amount) if round else to_amount)
