docstr: Retrieve OHLCV candles for the given assets
  
  Parameters
  ----------
  freq: str
      The frequency alias per convention:
      http://pandas.pydata.org/pandas-docs/stable/timeseries.html#offset-aliases
  
  assets: list[TradingPair]
      The targeted assets.
  
  bar_count: int
      The number of bar desired. (default 1)
  
  end_dt: datetime, optional
      The last bar date.
  
  start_dt: datetime, optional
      The first bar date.
  
  Returns
  -------
  dict[TradingPair, dict[str, Object]]
      A dictionary of OHLCV candles. Each TradingPair instance is
      mapped to a list of dictionaries with this structure:
          open: float
          high: float
          low: float
          close: float
          volume: float
          last_traded: datetime
  
      See definition here:
          http://www.investopedia.com/terms/o/ohlcchart.asp
docstr_tok: ["Retrieve","OHLCV","candles","for","the","given","assets","Parameters","--","--","--","--","--","freq",":","str","The","frequency","alias","per","convention",":","http",":","\/\/pandas.pydata.org\/pandas-docs\/stable\/timeseries.html","#","offset-aliases","assets",":","list","[","TradingPair","]","The","targeted","assets",".","bar_count",":","int","The","number","of","bar","desired",".","(","default","1",")","end_dt",":","datetime",",","optional","The","last","bar","date",".","start_dt",":","datetime",",","optional","The","first","bar","date",".","Returns","--","--","--","-","dict","[","TradingPair",",","dict","[","str",",","Object","]","]","A","dictionary","of","OHLCV","candles",".","Each","TradingPair","instance","is","mapped","to","a","list","of","dictionaries","with","this","structure",":","open",":","float","high",":","float","low",":","float","close",":","float","volume",":","float","last_traded",":","datetime","See","definition","here",":","http",":","\/\/www.investopedia.com\/terms\/o\/ohlcchart.asp"]
code: def get_candles(
      self, freq, assets, bar_count, start_dt=None, end_dt=None
  ):
      """
      Retrieve OHLCV candles for the given assets
  
      Parameters
      ----------
      freq: str
          The frequency alias per convention:
          http://pandas.pydata.org/pandas-docs/stable/timeseries.html#offset-aliases
  
      assets: list[TradingPair]
          The targeted assets.
  
      bar_count: int
          The number of bar desired. (default 1)
  
      end_dt: datetime, optional
          The last bar date.
  
      start_dt: datetime, optional
          The first bar date.
  
      Returns
      -------
      dict[TradingPair, dict[str, Object]]
          A dictionary of OHLCV candles. Each TradingPair instance is
          mapped to a list of dictionaries with this structure:
              open: float
              high: float
              low: float
              close: float
              volume: float
              last_traded: datetime
  
          See definition here:
              http://www.investopedia.com/terms/o/ohlcchart.asp
      """
      pass
  
imports: import abc
  from abc import ABCMeta, abstractmethod, abstractproperty
  from datetime import timedelta
  from time import sleep
  import numpy
  import pandas
  from catalyst.constants import LOG_LEVEL
  from catalyst.data.data_portal import BASE_FIELDS
  from catalyst.exchange.exchange_bundle import ExchangeBundle
  from catalyst.exchange.exchange_errors import MismatchingQuoteCurrencies, SymbolNotFoundOnExchange, PricingDataNotLoadedError, NoDataAvailableOnExchange, NoValueForField, NoCandlesReceivedFromExchange, TickerNotFoundError, NotEnoughCashError
  from catalyst.exchange.utils.datetime_utils import get_delta, get_periods_range, get_periods, get_start_dt, get_frequency, get_candles_number_from_minutes
  from catalyst.exchange.utils.exchange_utils import get_exchange_symbols, resample_history_df, has_bundle, get_candles_df
  from logbook import Logger
label_desc: Use image node_id 28 for calling the Exchange obj's underlying member method code with example usage: obj.get_candles(freq, assets, bar_count, start_dt, end_dt) without return types