@asyncio.coroutine<EOL>def create_ethereum_client(uri, timeout=<NUM_LIT>, *, loop=None):
if loop is None:<EOL><INDENT>loop = asyncio.get_event_loop()<EOL><DEDENT>presult = urlparse(uri)<EOL>if presult.scheme in ('<STR_LIT>', '<STR_LIT>'):<EOL><INDENT>reader, writer = yield from asyncio.open_unix_connection(presult.path,<EOL>loop=loop)<EOL>return AsyncIOIPCClient(reader, writer, uri, timeout, loop=loop)<EOL><DEDENT>elif presult.scheme in ('<STR_LIT:http>', '<STR_LIT>'):<EOL><INDENT>tls = presult.scheme[-<NUM_LIT:1>] == '<STR_LIT:s>'<EOL>netloc = presult.netloc.split('<STR_LIT::>')<EOL>host = netloc.pop(<NUM_LIT:0>)<EOL>port = netloc.pop(<NUM_LIT:0>) if netloc else (<NUM_LIT> if tls else <NUM_LIT>)<EOL>return AsyncIOHTTPClient(host, port, tls, timeout, loop=loop)<EOL><DEDENT>else:<EOL><INDENT>raise RuntimeError('<STR_LIT>')<EOL><DEDENT>
Create client to ethereum node based on schema.

    :param uri: Host on ethereum node
    :type uri: str

    :param timeout: An optional total time of timeout call
    :type timeout: int

    :param loop: An optional *event loop* instance
                 (uses :func:`asyncio.get_event_loop` if not specified).
    :type loop: :ref:`EventLoop<asyncio-event-loop>`

    :return: :class:`BaseAsyncIOClient` instance.