code: def test_invalid_isub():
      # Quantity with negative difference
      q = Quantity(BTC, 1000)
      with pytest.raises(InvalidNegativeQuantity):
          q -= Quantity(BTC, 1500)
  
      # Quantity with different instruments
      q = Quantity(BTC, 1000)
      with pytest.raises(IncompatibleInstrumentOperation):
          q -= Quantity(ETH, 500)
  
      # Quantity with different Path IDs
      q = Quantity(BTC, 1000, path_id=path_id)
      with pytest.raises(QuantityOpPathMismatch):
          q -= Quantity(BTC, 500, path_id=other_id)
  
      # int
      q = Quantity(BTC, 1000)
      with pytest.raises(InvalidNegativeQuantity):
          q -= 1500
  
      # float
      q = Quantity(BTC, 1000)
      with pytest.raises(InvalidNegativeQuantity):
          q -= 1500
  
      # Not a number
      q = Quantity(ETH, 5)
      with pytest.raises(InvalidNonNumericQuantity):
          q -= "BTC"
  
imports: import pytest
  import unittest.mock
  from tensortrade.oms.instruments import *
  from tensortrade.core.exceptions import *
label_desc: Use image node_id 11 for calling a global function with example usage: test_invalid_isub() without return types