Get database IDs (DB_IDs), given a set of GO IDs.
331747
def get_ids_g_goids(self, goids):
        """"""
        return set(nt.DB_ID for nt in self.associations if nt.GO_ID in goids)
766346
def get_id2gos_all(taxid2asscs_a2b):
        """"""
        id2gos_all = {}
        for a2b in taxid2asscs_a2b.values():
            for geneid, gos in a2b['ID2GOs'].items():
                id2gos_all[geneid] = gos
        return id2gos_all
282784
def system_find_databases(input_params={}, always_retry=True, **kwargs):
    
    return DXHTTPRequest('/system/findDatabases', input_params, always_retry=always_retry, **kwargs)
286900
def getIndexes(self) :
        """"""
        url = "%s/index" % self.database.URL
        r = self.connection.session.get(url, params = {"collection": self.name})
        data = r.json()
        for ind in data["indexes"] :
            self.indexes[ind["type"]][ind["id"]] = Index(collection = self, infos = ind)

        return self.indexes
88360
def _get_requested_databases(self):
        """"""
        requested_databases = []
        if ((self._requested_namespaces is not None) and
                (self._requested_namespaces != [])):
            for requested_namespace in self._requested_namespaces:
                if requested_namespace[0] is '*':
                    return []
                elif requested_namespace[0] not in IGNORE_DBS:
                    requested_databases.append(requested_namespace[0])
        return requested_databases
254158
def _init_usrgos(self, goids):
        """"""
        usrgos = set()
        goids_missing = set()
        _go2obj = self.gosubdag.go2obj
        for goid in goids:
            if goid in _go2obj:
                usrgos.add(goid)
            else:
                goids_missing.add(goid)
        if goids_missing:
            print("MISSING GO IDs: {GOs}".format(GOs=goids_missing))
            print("{N} of {M} GO IDs ARE MISSING".format(N=len(goids_missing), M=len(goids)))
        return usrgos
525777
def fetch_column_names(cls,
                           db: DATABASE_SUPPORTER_FWD_REF,
                           table: str) -> List[str]:
        """"""
        raise RuntimeError(_MSG_NO_FLAVOUR)
781783
def get_new_oids(self):
        '''
        
        '''
        table = self.lconfig.get('table')
        _oid = self.lconfig.get('_oid')
        if is_array(_oid):
            _oid = _oid[0]  # get the db column, not the field alias
        last_id = self.container.get_last_field(field='_oid')
        ids = []
        if last_id:
            try:  # try to convert to integer... if not, assume unicode value
                last_id = float(last_id)
                where = "%s.%s > %s" % (table, _oid, last_id)
            except (TypeError, ValueError):
                where = "%s.%s > '%s'" % (table, _oid, last_id)
            ids = self.sql_get_oids(where)
        return ids
26670
def loaded_dataset_ids(self):
        """"""
        return set(ds_id for scene in self.scenes for ds_id in scene.keys())
529687
def _get_db_names(self, dbs, strict=True):
        
        dbs = utils.coerce_to_list(dbs)
        db_names = [utils.get_name(db) for db in dbs]
        if strict:
            good_dbs = self.instance.list_databases()
            good_names = [utils.get_name(good_db) for good_db in good_dbs]
            bad_names = [db_name for db_name in db_names
                    if db_name not in good_names]
            if bad_names:
                bad = ", ".join(bad_names)
                raise exc.NoSuchDatabase("The following database(s) were not "
                        "found: %s" % bad)
        return db_names
988473
def get_item_ids(self):
        """"""
        item_ids = []
        if self.has_items():
            for idstr in self._my_map['itemIds']:
                item_ids.append(idstr)
        return IdList(item_ids)
1220565
def getNetworkIDs(self):
        """"""

        res = []
        i = 0
        while True:
            netid = self.getValue("net_interface.%d.connection" % i)
            if not netid:
                return res
            res.append(netid)
            i += 1
686321
def _get_id2gos(self, associations, **kws):
        """"""
        options = AnnoOptions(self.evobj, **kws)
        # Default reduction is to remove. For all options, see goatools/anno/opts.py:
        #   * Evidence_Code == ND -> No biological data No biological Data available
        #   * Qualifiers contain NOT
        assc = self.reduce_annotations(associations, options)
        return self._get_dbid2goids(assc) if options.b_geneid2gos else self._get_goid2dbids(assc)
460971
def query_ids(self, ids):
        

        results = self._get_repo_filter(Layer.objects).filter(uuid__in=ids).all()

        if len(results) == 0:  # try services
            results = self._get_repo_filter(Service.objects).filter(uuid__in=ids).all()

        return results
273170
def running_objects(self):
        """"""
        return [obj for obj in self.database_objects
                if obj.status in [obj.known_statuses.RUNNING]]
286868
def ids(self):
        
        if self._ids is None:
            if self._columns:
                if isinstance(self._columns, OrderedDict):
                    return [list(self._columns.keys())[0]]
                return [self._columns[0]]
        else:
            return self._ids
1288340
def get_tables(self, db_name, pattern):
    
    self.send_get_tables(db_name, pattern)
    return self.recv_get_tables()