'Install autotest_remote on any current job hosts.'

def _install_clients(self):

    in_use_hosts = set()
    for host in self.job.hosts:
        autodir = host.get_autodir()
        if (not (autodir and autodir.startswith(PROFILER_TMPDIR))):
            in_use_hosts.add(host.hostname)
    logging.debug('Hosts    currently    in    use:    %s', in_use_hosts)
    profiler_hosts = set()
    for (host, at, profiler_dir) in self.installed_hosts.values():
        if host.path_exists(profiler_dir):
            profiler_hosts.add(host.hostname)
        else:
            logging.warning('The    profiler    client    on    %s    at    %s    was    deleted', host.hostname, profiler_dir)
            host.close()
            del self.installed_hosts[host.hostname]
    logging.debug('Hosts    with    profiler    clients    already    installed:    %s', profiler_hosts)
    for hostname in (in_use_hosts - profiler_hosts):
        host = hosts.create_host(hostname, auto_monitor=False)
        tmp_dir = host.get_tmp_dir(parent=PROFILER_TMPDIR)
        at = autotest_remote.Autotest(host)
        at.install_no_autoserv(autodir=tmp_dir)
        self.installed_hosts[host.hostname] = (host, at, tmp_dir)
    hostnames_to_drop = (profiler_hosts - in_use_hosts)
    hosts_to_drop = [self.installed_hosts[hostname][0] for hostname in hostnames_to_drop]
    for host in hosts_to_drop:
        host.close()
        del self.installed_hosts[host.hostname]
