sentence1
stringlengths
52
3.87M
sentence2
stringlengths
1
47.2k
label
stringclasses
1 value
def _add_to_ref(self, rec_curr, line, lnum): """Add new fields to the current reference.""" # Written by DV Klopfenstein # Examples of record lines containing ':' include: # id: GO:0000002 # name: mitochondrial genome maintenance # namespace: biological_process ...
Add new fields to the current reference.
entailment
def update_rec(self, rec, name, value): """Update current GOTerm with optional record.""" # 'def' is a reserved word in python, do not use it as a Class attr. if name == "def": name = "defn" # If we have a relationship, then we will split this into a further # dictio...
Update current GOTerm with optional record.
entailment
def _add_to_typedef(self, typedef_curr, line, lnum): """Add new fields to the current typedef.""" mtch = re.match(r'^(\S+):\s*(\S.*)$', line) if mtch: field_name = mtch.group(1) field_value = mtch.group(2).split('!')[0].rstrip() if field_name == "id": ...
Add new fields to the current typedef.
entailment
def _add_nested(self, rec, name, value): """Adds a term's nested attributes.""" # Remove comments and split term into typedef / target term. (typedef, target_term) = value.split('!')[0].rstrip().split(' ') # Save the nested term. getattr(rec, name)[typedef].append(target_term)
Adds a term's nested attributes.
entailment
def _init_optional_attrs(self, optional_attrs): """Prepare to store data from user-desired optional fields. Not loading these optional fields by default saves in space and speed. But allow the possibility for saving these fields, if the user desires, Including: com...
Prepare to store data from user-desired optional fields. Not loading these optional fields by default saves in space and speed. But allow the possibility for saving these fields, if the user desires, Including: comment consider def is_class_level is_metadata_tag is_transit...
entailment
def _die(self, msg, lnum): """Raise an Exception if file read is unexpected.""" raise Exception("**FATAL {FILE}({LNUM}): {MSG}\n".format( FILE=self.obo_file, LNUM=lnum, MSG=msg))
Raise an Exception if file read is unexpected.
entailment
def write_hier_rec(self, gos_printed, out=sys.stdout, len_dash=1, max_depth=None, num_child=None, short_prt=False, include_only=None, go_marks=None, depth=1, dp="-"): """Write hierarchy for a GO Term record.""" # Added by DV Klopfenstein ...
Write hierarchy for a GO Term record.
entailment
def write_hier_all(self, out=sys.stdout, len_dash=1, max_depth=None, num_child=None, short_prt=False): """Write hierarchy for all GO Terms in obo file.""" # Print: [biological_process, molecular_function, and cellular_component] for go_id in ['GO:0008150', 'GO:0003674', 'GO...
Write hierarchy for all GO Terms in obo file.
entailment
def write_hier(self, GO_id, out=sys.stdout, len_dash=1, max_depth=None, num_child=None, short_prt=False, include_only=None, go_marks=None): """Write hierarchy for a GO Term.""" gos_printed = set() self[GO_id].write_hier_rec(gos_printed, out, len_dash...
Write hierarchy for a GO Term.
entailment
def paths_to_top(self, term): """ Returns all possible paths to the root node Each path includes the term given. The order of the path is top -> bottom, i.e. it starts with the root and ends with the given term (inclusively). Parameters: ----------- ...
Returns all possible paths to the root node Each path includes the term given. The order of the path is top -> bottom, i.e. it starts with the root and ends with the given term (inclusively). Parameters: ----------- - term: the id...
entailment
def make_graph_pydot(self, recs, nodecolor, edgecolor, dpi, draw_parents=True, draw_children=True): """draw AMIGO style network, lineage containing one query record.""" import pydot G = pydot.Dot(graph_type='digraph', dpi="{}".format(dpi)) # Directed Gra...
draw AMIGO style network, lineage containing one query record.
entailment
def sqliteRowsToDicts(sqliteRows): """ Unpacks sqlite rows as returned by fetchall into an array of simple dicts. :param sqliteRows: array of rows returned from fetchall DB call :return: array of dicts, keyed by the column names. """ return map(lambda r: dict(zip(r.keys(), r)), sqliteRows)
Unpacks sqlite rows as returned by fetchall into an array of simple dicts. :param sqliteRows: array of rows returned from fetchall DB call :return: array of dicts, keyed by the column names.
entailment
def limitsSql(startIndex=0, maxResults=0): """ Construct a SQL LIMIT clause """ if startIndex and maxResults: return " LIMIT {}, {}".format(startIndex, maxResults) elif startIndex: raise Exception("startIndex was provided, but maxResults was not") elif maxResults: return ...
Construct a SQL LIMIT clause
entailment
def iterativeFetch(query, batchSize=default_batch_size): """ Returns rows of a sql fetch query on demand """ while True: rows = query.fetchmany(batchSize) if not rows: break rowDicts = sqliteRowsToDicts(rows) for rowDict in rowDicts: yield rowDict
Returns rows of a sql fetch query on demand
entailment
def _parsePageToken(pageToken, numValues): """ Parses the specified pageToken and returns a list of the specified number of values. Page tokens are assumed to consist of a fixed number of integers seperated by colons. If the page token does not conform to this specification, raise a InvalidPageToken...
Parses the specified pageToken and returns a list of the specified number of values. Page tokens are assumed to consist of a fixed number of integers seperated by colons. If the page token does not conform to this specification, raise a InvalidPageToken exception.
entailment
def _parseIntegerArgument(args, key, defaultValue): """ Attempts to parse the specified key in the specified argument dictionary into an integer. If the argument cannot be parsed, raises a BadRequestIntegerException. If the key is not present, return the specified default value. """ ret = de...
Attempts to parse the specified key in the specified argument dictionary into an integer. If the argument cannot be parsed, raises a BadRequestIntegerException. If the key is not present, return the specified default value.
entailment
def _initialiseIteration(self): """ Starts a new iteration. """ self._searchIterator = self._search( self._request.start, self._request.end if self._request.end != 0 else None) self._currentObject = next(self._searchIterator, None) if self._current...
Starts a new iteration.
entailment
def _pickUpIteration(self, searchAnchor, objectsToSkip): """ Picks up iteration from a previously provided page token. There are two different phases here: 1) We are iterating over the initial set of intervals in which start is < the search start coorindate. 2) We are ite...
Picks up iteration from a previously provided page token. There are two different phases here: 1) We are iterating over the initial set of intervals in which start is < the search start coorindate. 2) We are iterating over the remaining intervals in which start >= to the search s...
entailment
def next(self): """ Returns the next (object, nextPageToken) pair. """ if self._currentObject is None: raise StopIteration() nextPageToken = None if self._nextObject is not None: start = self._getStart(self._nextObject) # If start > the...
Returns the next (object, nextPageToken) pair.
entailment
def filterVariantAnnotation(self, vann): """ Returns true when an annotation should be included. """ # TODO reintroduce feature ID search ret = False if len(self._effects) != 0 and not vann.transcript_effects: return False elif len(self._effects) == 0:...
Returns true when an annotation should be included.
entailment
def filterEffect(self, teff): """ Returns true when any of the transcript effects are present in the request. """ ret = False for effect in teff.effects: ret = self._matchAnyEffects(effect) or ret return ret
Returns true when any of the transcript effects are present in the request.
entailment
def _checkIdEquality(self, requestedEffect, effect): """ Tests whether a requested effect and an effect present in an annotation are equal. """ return self._idPresent(requestedEffect) and ( effect.term_id == requestedEffect.term_id)
Tests whether a requested effect and an effect present in an annotation are equal.
entailment
def ga4ghImportGlue(): """ Call this method before importing a ga4gh module in the scripts dir. Otherwise, you will be using the installed package instead of the development package. Assumes a certain directory structure. """ path = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))...
Call this method before importing a ga4gh module in the scripts dir. Otherwise, you will be using the installed package instead of the development package. Assumes a certain directory structure.
entailment
def _update(self, dataFile, handle): """ Update the priority of the file handle. The element is first removed and then added to the left of the deque. """ self._cache.remove((dataFile, handle)) self._add(dataFile, handle)
Update the priority of the file handle. The element is first removed and then added to the left of the deque.
entailment
def _removeLru(self): """ Remove the least recently used file handle from the cache. The pop method removes an element from the right of the deque. Returns the name of the file that has been removed. """ (dataFile, handle) = self._cache.pop() handle.close() ...
Remove the least recently used file handle from the cache. The pop method removes an element from the right of the deque. Returns the name of the file that has been removed.
entailment
def getFileHandle(self, dataFile, openMethod): """ Returns handle associated to the filename. If the file is already opened, update its priority in the cache and return its handle. Otherwise, open the file using openMethod, store it in the cache and return the corresponding handl...
Returns handle associated to the filename. If the file is already opened, update its priority in the cache and return its handle. Otherwise, open the file using openMethod, store it in the cache and return the corresponding handle.
entailment
def join(cls, splits): """ Join an array of ids into a compound id string """ segments = [] for split in splits: segments.append('"{}",'.format(split)) if len(segments) > 0: segments[-1] = segments[-1][:-1] jsonString = '[{}]'.format(''.joi...
Join an array of ids into a compound id string
entailment
def parse(cls, compoundIdStr): """ Parses the specified compoundId string and returns an instance of this CompoundId class. :raises: An ObjectWithIdNotFoundException if parsing fails. This is because this method is a client-facing method, and if a malformed identifier (u...
Parses the specified compoundId string and returns an instance of this CompoundId class. :raises: An ObjectWithIdNotFoundException if parsing fails. This is because this method is a client-facing method, and if a malformed identifier (under our internal rules) is provided, the response ...
entailment
def obfuscate(cls, idStr): """ Mildly obfuscates the specified ID string in an easily reversible fashion. This is not intended for security purposes, but rather to dissuade users from depending on our internal ID structures. """ return unicode(base64.urlsafe_b64encode( ...
Mildly obfuscates the specified ID string in an easily reversible fashion. This is not intended for security purposes, but rather to dissuade users from depending on our internal ID structures.
entailment
def deobfuscate(cls, data): """ Reverses the obfuscation done by the :meth:`obfuscate` method. If an identifier arrives without correct base64 padding this function will append it to the end. """ # the str() call is necessary to convert the unicode string # to an ...
Reverses the obfuscation done by the :meth:`obfuscate` method. If an identifier arrives without correct base64 padding this function will append it to the end.
entailment
def serializeAttributes(self, msg): """ Sets the attrbutes of a message during serialization. """ attributes = self.getAttributes() for key in attributes: protocol.setAttribute( msg.attributes.attr[key].values, attributes[key]) return msg
Sets the attrbutes of a message during serialization.
entailment
def _scanDataFiles(self, dataDir, patterns): """ Scans the specified directory for files with the specified globbing pattern and calls self._addDataFile for each. Raises an EmptyDirException if no data files are found. """ numDataFiles = 0 for pattern in patterns:...
Scans the specified directory for files with the specified globbing pattern and calls self._addDataFile for each. Raises an EmptyDirException if no data files are found.
entailment
def getInitialPeerList(filePath, logger=None): """ Attempts to get a list of peers from a file specified in configuration. This file has one URL per line and can contain newlines and comments. # Main ga4gh node http://1kgenomes.ga4gh.org # Local intranet peer https://192.16...
Attempts to get a list of peers from a file specified in configuration. This file has one URL per line and can contain newlines and comments. # Main ga4gh node http://1kgenomes.ga4gh.org # Local intranet peer https://192.168.1.1 The server will attempt to add URLs in this file...
entailment
def insertInitialPeer(dataRepository, url, logger=None): """ Takes the datarepository, a url, and an optional logger and attempts to add the peer into the repository. """ insertPeer = dataRepository.insertPeer try: peer = datamodel.peers.Peer(url) insertPeer(peer) except exce...
Takes the datarepository, a url, and an optional logger and attempts to add the peer into the repository.
entailment
def isUrl(urlString): """ Attempts to return whether a given URL string is valid by checking for the presence of the URL scheme and netloc using the urlparse module, and then using a regex. From http://stackoverflow.com/questions/7160737/ """ parsed = urlparse.urlparse(urlString) urlpar...
Attempts to return whether a given URL string is valid by checking for the presence of the URL scheme and netloc using the urlparse module, and then using a regex. From http://stackoverflow.com/questions/7160737/
entailment
def setUrl(self, url): """ Attempt to safely set the URL by string. """ if isUrl(url): self._url = url else: raise exceptions.BadUrlException(url) return self
Attempt to safely set the URL by string.
entailment
def setAttributesJson(self, attributesJson): """ Sets the attributes dictionary from a JSON string. """ try: self._attributes = json.loads(attributesJson) except: raise exceptions.InvalidJsonException(attributesJson) return self
Sets the attributes dictionary from a JSON string.
entailment
def populateFromRow(self, peerRecord): """ This method accepts a model record and sets class variables. """ self.setUrl(peerRecord.url) \ .setAttributesJson(peerRecord.attributes) return self
This method accepts a model record and sets class variables.
entailment
def _topLevelObjectGenerator(self, request, numObjects, getByIndexMethod): """ Returns a generator over the results for the specified request, which is over a set of objects of the specified size. The objects are returned by call to the specified method, which must take a single ...
Returns a generator over the results for the specified request, which is over a set of objects of the specified size. The objects are returned by call to the specified method, which must take a single integer as an argument. The returned generator yields a sequence of (object, nextPageTo...
entailment
def _protocolObjectGenerator(self, request, numObjects, getByIndexMethod): """ Returns a generator over the results for the specified request, from a set of protocol objects of the specified size. The objects are returned by call to the specified method, which must take a single ...
Returns a generator over the results for the specified request, from a set of protocol objects of the specified size. The objects are returned by call to the specified method, which must take a single integer as an argument. The returned generator yields a sequence of (object, nextPageTo...
entailment
def _protocolListGenerator(self, request, objectList): """ Returns a generator over the objects in the specified list using _protocolObjectGenerator to generate page tokens. """ return self._protocolObjectGenerator( request, len(objectList), lambda index: objectList[i...
Returns a generator over the objects in the specified list using _protocolObjectGenerator to generate page tokens.
entailment
def _objectListGenerator(self, request, objectList): """ Returns a generator over the objects in the specified list using _topLevelObjectGenerator to generate page tokens. """ return self._topLevelObjectGenerator( request, len(objectList), lambda index: objectList[ind...
Returns a generator over the objects in the specified list using _topLevelObjectGenerator to generate page tokens.
entailment
def datasetsGenerator(self, request): """ Returns a generator over the (dataset, nextPageToken) pairs defined by the specified request """ return self._topLevelObjectGenerator( request, self.getDataRepository().getNumDatasets(), self.getDataRepository().ge...
Returns a generator over the (dataset, nextPageToken) pairs defined by the specified request
entailment
def phenotypeAssociationSetsGenerator(self, request): """ Returns a generator over the (phenotypeAssociationSet, nextPageToken) pairs defined by the specified request """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._topLevelObjectGenerato...
Returns a generator over the (phenotypeAssociationSet, nextPageToken) pairs defined by the specified request
entailment
def readGroupSetsGenerator(self, request): """ Returns a generator over the (readGroupSet, nextPageToken) pairs defined by the specified request. """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._readGroupSetsGenerator( request...
Returns a generator over the (readGroupSet, nextPageToken) pairs defined by the specified request.
entailment
def _readGroupSetsGenerator(self, request, numObjects, getByIndexMethod): """ Returns a generator over the results for the specified request, which is over a set of objects of the specified size. The objects are returned by call to the specified method, which must take a single i...
Returns a generator over the results for the specified request, which is over a set of objects of the specified size. The objects are returned by call to the specified method, which must take a single integer as an argument. The returned generator yields a sequence of (object, nextPageTo...
entailment
def referenceSetsGenerator(self, request): """ Returns a generator over the (referenceSet, nextPageToken) pairs defined by the specified request. """ results = [] for obj in self.getDataRepository().getReferenceSets(): include = True if request.md5...
Returns a generator over the (referenceSet, nextPageToken) pairs defined by the specified request.
entailment
def referencesGenerator(self, request): """ Returns a generator over the (reference, nextPageToken) pairs defined by the specified request. """ referenceSet = self.getDataRepository().getReferenceSet( request.reference_set_id) results = [] for obj in r...
Returns a generator over the (reference, nextPageToken) pairs defined by the specified request.
entailment
def variantSetsGenerator(self, request): """ Returns a generator over the (variantSet, nextPageToken) pairs defined by the specified request. """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._topLevelObjectGenerator( request, d...
Returns a generator over the (variantSet, nextPageToken) pairs defined by the specified request.
entailment
def variantAnnotationSetsGenerator(self, request): """ Returns a generator over the (variantAnnotationSet, nextPageToken) pairs defined by the specified request. """ compoundId = datamodel.VariantSetCompoundId.parse( request.variant_set_id) dataset = self.getD...
Returns a generator over the (variantAnnotationSet, nextPageToken) pairs defined by the specified request.
entailment
def readsGenerator(self, request): """ Returns a generator over the (read, nextPageToken) pairs defined by the specified request """ if not request.reference_id: raise exceptions.UnmappedReadsNotSupported() if len(request.read_group_ids) < 1: raise...
Returns a generator over the (read, nextPageToken) pairs defined by the specified request
entailment
def variantsGenerator(self, request): """ Returns a generator over the (variant, nextPageToken) pairs defined by the specified request. """ compoundId = datamodel.VariantSetCompoundId \ .parse(request.variant_set_id) dataset = self.getDataRepository().getDatas...
Returns a generator over the (variant, nextPageToken) pairs defined by the specified request.
entailment
def variantAnnotationsGenerator(self, request): """ Returns a generator over the (variantAnnotaitons, nextPageToken) pairs defined by the specified request. """ compoundId = datamodel.VariantAnnotationSetCompoundId.parse( request.variant_annotation_set_id) dat...
Returns a generator over the (variantAnnotaitons, nextPageToken) pairs defined by the specified request.
entailment
def featuresGenerator(self, request): """ Returns a generator over the (features, nextPageToken) pairs defined by the (JSON string) request. """ compoundId = None parentId = None if request.feature_set_id != "": compoundId = datamodel.FeatureSetCompoun...
Returns a generator over the (features, nextPageToken) pairs defined by the (JSON string) request.
entailment
def continuousGenerator(self, request): """ Returns a generator over the (continuous, nextPageToken) pairs defined by the (JSON string) request. """ compoundId = None if request.continuous_set_id != "": compoundId = datamodel.ContinuousSetCompoundId.parse( ...
Returns a generator over the (continuous, nextPageToken) pairs defined by the (JSON string) request.
entailment
def phenotypesGenerator(self, request): """ Returns a generator over the (phenotypes, nextPageToken) pairs defined by the (JSON string) request """ # TODO make paging work using SPARQL? compoundId = datamodel.PhenotypeAssociationSetCompoundId.parse( request.ph...
Returns a generator over the (phenotypes, nextPageToken) pairs defined by the (JSON string) request
entailment
def genotypesPhenotypesGenerator(self, request): """ Returns a generator over the (phenotypes, nextPageToken) pairs defined by the (JSON string) request """ # TODO make paging work using SPARQL? compoundId = datamodel.PhenotypeAssociationSetCompoundId.parse( r...
Returns a generator over the (phenotypes, nextPageToken) pairs defined by the (JSON string) request
entailment
def callSetsGenerator(self, request): """ Returns a generator over the (callSet, nextPageToken) pairs defined by the specified request. """ compoundId = datamodel.VariantSetCompoundId.parse( request.variant_set_id) dataset = self.getDataRepository().getDataset...
Returns a generator over the (callSet, nextPageToken) pairs defined by the specified request.
entailment
def featureSetsGenerator(self, request): """ Returns a generator over the (featureSet, nextPageToken) pairs defined by the specified request. """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._topLevelObjectGenerator( request, d...
Returns a generator over the (featureSet, nextPageToken) pairs defined by the specified request.
entailment
def continuousSetsGenerator(self, request): """ Returns a generator over the (continuousSet, nextPageToken) pairs defined by the specified request. """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._topLevelObjectGenerator( requ...
Returns a generator over the (continuousSet, nextPageToken) pairs defined by the specified request.
entailment
def rnaQuantificationSetsGenerator(self, request): """ Returns a generator over the (rnaQuantificationSet, nextPageToken) pairs defined by the specified request. """ dataset = self.getDataRepository().getDataset(request.dataset_id) return self._topLevelObjectGenerator( ...
Returns a generator over the (rnaQuantificationSet, nextPageToken) pairs defined by the specified request.
entailment
def rnaQuantificationsGenerator(self, request): """ Returns a generator over the (rnaQuantification, nextPageToken) pairs defined by the specified request. """ if len(request.rna_quantification_set_id) < 1: raise exceptions.BadRequestException( "Rna Qu...
Returns a generator over the (rnaQuantification, nextPageToken) pairs defined by the specified request.
entailment
def expressionLevelsGenerator(self, request): """ Returns a generator over the (expressionLevel, nextPageToken) pairs defined by the specified request. Currently only supports searching over a specified rnaQuantification """ rnaQuantificationId = request.rna_quantificati...
Returns a generator over the (expressionLevel, nextPageToken) pairs defined by the specified request. Currently only supports searching over a specified rnaQuantification
entailment
def runGetRequest(self, obj): """ Runs a get request by converting the specified datamodel object into its protocol representation. """ protocolElement = obj.toProtocolElement() jsonString = protocol.toJson(protocolElement) return jsonString
Runs a get request by converting the specified datamodel object into its protocol representation.
entailment
def runSearchRequest( self, requestStr, requestClass, responseClass, objectGenerator): """ Runs the specified request. The request is a string containing a JSON representation of an instance of the specified requestClass. We return a string representation of an instance of th...
Runs the specified request. The request is a string containing a JSON representation of an instance of the specified requestClass. We return a string representation of an instance of the specified responseClass in JSON format. Objects are filled into the page list using the specified obj...
entailment
def runListReferenceBases(self, requestJson): """ Runs a listReferenceBases request for the specified ID and request arguments. """ # In the case when an empty post request is made to the endpoint # we instantiate an empty ListReferenceBasesRequest. if not request...
Runs a listReferenceBases request for the specified ID and request arguments.
entailment
def runGetCallSet(self, id_): """ Returns a callset with the given id """ compoundId = datamodel.CallSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) variantSet = dataset.getVariantSet(compoundId.variant_set_id) callSet...
Returns a callset with the given id
entailment
def runGetInfo(self, request): """ Returns information about the service including protocol version. """ return protocol.toJson(protocol.GetInfoResponse( protocol_version=protocol.version))
Returns information about the service including protocol version.
entailment
def runAddAnnouncement(self, flaskrequest): """ Takes a flask request from the frontend and attempts to parse into an AnnouncePeerRequest. If successful, it will log the announcement to the `announcement` table with some other metadata gathered from the request. """ ...
Takes a flask request from the frontend and attempts to parse into an AnnouncePeerRequest. If successful, it will log the announcement to the `announcement` table with some other metadata gathered from the request.
entailment
def runListPeers(self, request): """ Takes a ListPeersRequest and returns a ListPeersResponse using a page_token and page_size if provided. """ return self.runSearchRequest( request, protocol.ListPeersRequest, protocol.ListPeersResponse, ...
Takes a ListPeersRequest and returns a ListPeersResponse using a page_token and page_size if provided.
entailment
def runGetVariant(self, id_): """ Returns a variant with the given id """ compoundId = datamodel.VariantCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) variantSet = dataset.getVariantSet(compoundId.variant_set_id) gaVaria...
Returns a variant with the given id
entailment
def runGetBiosample(self, id_): """ Runs a getBiosample request for the specified ID. """ compoundId = datamodel.BiosampleCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) biosample = dataset.getBiosample(id_) return self.r...
Runs a getBiosample request for the specified ID.
entailment
def runGetIndividual(self, id_): """ Runs a getIndividual request for the specified ID. """ compoundId = datamodel.BiosampleCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) individual = dataset.getIndividual(id_) return se...
Runs a getIndividual request for the specified ID.
entailment
def runGetFeature(self, id_): """ Returns JSON string of the feature object corresponding to the feature compoundID passed in. """ compoundId = datamodel.FeatureCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) featureSet =...
Returns JSON string of the feature object corresponding to the feature compoundID passed in.
entailment
def runGetReadGroupSet(self, id_): """ Returns a readGroupSet with the given id_ """ compoundId = datamodel.ReadGroupSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) readGroupSet = dataset.getReadGroupSet(id_) return se...
Returns a readGroupSet with the given id_
entailment
def runGetReadGroup(self, id_): """ Returns a read group with the given id_ """ compoundId = datamodel.ReadGroupCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) readGroupSet = dataset.getReadGroupSet(compoundId.read_group_set_id) ...
Returns a read group with the given id_
entailment
def runGetReference(self, id_): """ Runs a getReference request for the specified ID. """ compoundId = datamodel.ReferenceCompoundId.parse(id_) referenceSet = self.getDataRepository().getReferenceSet( compoundId.reference_set_id) reference = referenceSet.getRe...
Runs a getReference request for the specified ID.
entailment
def runGetReferenceSet(self, id_): """ Runs a getReferenceSet request for the specified ID. """ referenceSet = self.getDataRepository().getReferenceSet(id_) return self.runGetRequest(referenceSet)
Runs a getReferenceSet request for the specified ID.
entailment
def runGetVariantSet(self, id_): """ Runs a getVariantSet request for the specified ID. """ compoundId = datamodel.VariantSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) variantSet = dataset.getVariantSet(id_) return s...
Runs a getVariantSet request for the specified ID.
entailment
def runGetFeatureSet(self, id_): """ Runs a getFeatureSet request for the specified ID. """ compoundId = datamodel.FeatureSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) featureSet = dataset.getFeatureSet(id_) return s...
Runs a getFeatureSet request for the specified ID.
entailment
def runGetContinuousSet(self, id_): """ Runs a getContinuousSet request for the specified ID. """ compoundId = datamodel.ContinuousSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) continuousSet = dataset.getContinuousSet(id_) ...
Runs a getContinuousSet request for the specified ID.
entailment
def runGetDataset(self, id_): """ Runs a getDataset request for the specified ID. """ dataset = self.getDataRepository().getDataset(id_) return self.runGetRequest(dataset)
Runs a getDataset request for the specified ID.
entailment
def runGetVariantAnnotationSet(self, id_): """ Runs a getVariantSet request for the specified ID. """ compoundId = datamodel.VariantAnnotationSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) variantSet = dataset.getVariantSet(c...
Runs a getVariantSet request for the specified ID.
entailment
def runGetRnaQuantification(self, id_): """ Runs a getRnaQuantification request for the specified ID. """ compoundId = datamodel.RnaQuantificationCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) rnaQuantificationSet = dataset.getR...
Runs a getRnaQuantification request for the specified ID.
entailment
def runGetRnaQuantificationSet(self, id_): """ Runs a getRnaQuantificationSet request for the specified ID. """ compoundId = datamodel.RnaQuantificationSetCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) rnaQuantificationSet = dat...
Runs a getRnaQuantificationSet request for the specified ID.
entailment
def runGetExpressionLevel(self, id_): """ Runs a getExpressionLevel request for the specified ID. """ compoundId = datamodel.ExpressionLevelCompoundId.parse(id_) dataset = self.getDataRepository().getDataset(compoundId.dataset_id) rnaQuantificationSet = dataset.getRnaQuan...
Runs a getExpressionLevel request for the specified ID.
entailment
def runSearchReadGroupSets(self, request): """ Runs the specified SearchReadGroupSetsRequest. """ return self.runSearchRequest( request, protocol.SearchReadGroupSetsRequest, protocol.SearchReadGroupSetsResponse, self.readGroupSetsGenerator)
Runs the specified SearchReadGroupSetsRequest.
entailment
def runSearchIndividuals(self, request): """ Runs the specified search SearchIndividualsRequest. """ return self.runSearchRequest( request, protocol.SearchIndividualsRequest, protocol.SearchIndividualsResponse, self.individualsGenerator)
Runs the specified search SearchIndividualsRequest.
entailment
def runSearchBiosamples(self, request): """ Runs the specified SearchBiosamplesRequest. """ return self.runSearchRequest( request, protocol.SearchBiosamplesRequest, protocol.SearchBiosamplesResponse, self.biosamplesGenerator)
Runs the specified SearchBiosamplesRequest.
entailment
def runSearchReads(self, request): """ Runs the specified SearchReadsRequest. """ return self.runSearchRequest( request, protocol.SearchReadsRequest, protocol.SearchReadsResponse, self.readsGenerator)
Runs the specified SearchReadsRequest.
entailment
def runSearchReferenceSets(self, request): """ Runs the specified SearchReferenceSetsRequest. """ return self.runSearchRequest( request, protocol.SearchReferenceSetsRequest, protocol.SearchReferenceSetsResponse, self.referenceSetsGenerator)
Runs the specified SearchReferenceSetsRequest.
entailment
def runSearchReferences(self, request): """ Runs the specified SearchReferenceRequest. """ return self.runSearchRequest( request, protocol.SearchReferencesRequest, protocol.SearchReferencesResponse, self.referencesGenerator)
Runs the specified SearchReferenceRequest.
entailment
def runSearchVariantSets(self, request): """ Runs the specified SearchVariantSetsRequest. """ return self.runSearchRequest( request, protocol.SearchVariantSetsRequest, protocol.SearchVariantSetsResponse, self.variantSetsGenerator)
Runs the specified SearchVariantSetsRequest.
entailment
def runSearchVariantAnnotationSets(self, request): """ Runs the specified SearchVariantAnnotationSetsRequest. """ return self.runSearchRequest( request, protocol.SearchVariantAnnotationSetsRequest, protocol.SearchVariantAnnotationSetsResponse, self.var...
Runs the specified SearchVariantAnnotationSetsRequest.
entailment
def runSearchVariants(self, request): """ Runs the specified SearchVariantRequest. """ return self.runSearchRequest( request, protocol.SearchVariantsRequest, protocol.SearchVariantsResponse, self.variantsGenerator)
Runs the specified SearchVariantRequest.
entailment
def runSearchVariantAnnotations(self, request): """ Runs the specified SearchVariantAnnotationsRequest. """ return self.runSearchRequest( request, protocol.SearchVariantAnnotationsRequest, protocol.SearchVariantAnnotationsResponse, self.variantAnnotati...
Runs the specified SearchVariantAnnotationsRequest.
entailment
def runSearchCallSets(self, request): """ Runs the specified SearchCallSetsRequest. """ return self.runSearchRequest( request, protocol.SearchCallSetsRequest, protocol.SearchCallSetsResponse, self.callSetsGenerator)
Runs the specified SearchCallSetsRequest.
entailment
def runSearchDatasets(self, request): """ Runs the specified SearchDatasetsRequest. """ return self.runSearchRequest( request, protocol.SearchDatasetsRequest, protocol.SearchDatasetsResponse, self.datasetsGenerator)
Runs the specified SearchDatasetsRequest.
entailment
def runSearchFeatureSets(self, request): """ Returns a SearchFeatureSetsResponse for the specified SearchFeatureSetsRequest object. """ return self.runSearchRequest( request, protocol.SearchFeatureSetsRequest, protocol.SearchFeatureSetsResponse, ...
Returns a SearchFeatureSetsResponse for the specified SearchFeatureSetsRequest object.
entailment
def runSearchFeatures(self, request): """ Returns a SearchFeaturesResponse for the specified SearchFeaturesRequest object. :param request: JSON string representing searchFeaturesRequest :return: JSON string representing searchFeatureResponse """ return self.runSe...
Returns a SearchFeaturesResponse for the specified SearchFeaturesRequest object. :param request: JSON string representing searchFeaturesRequest :return: JSON string representing searchFeatureResponse
entailment