Computed File

class pyrefinebio.ComputedFile(id=None, filename=None, samples=None, size_in_bytes=None, is_qn_target=None, is_smashable=None, is_qc=None, is_compendia=None, quant_sf_only=None, compendium_version=None, compendia_organism_name=None, sha1=None, s3_bucket=None, s3_key=None, s3_url=None, download_url=None, created_at=None, last_modified=None, result=None)

Computed File.

ComputedFiles are representation of files created by data-refinery processes.

Retrieve a ComputedFile based on id

>>> import pyrefinebio
>>> id = 1
>>> file = pyrefinebio.ComputedFile.get(id)

Retrieve a list of ComputedFile based on filters

>>> import pyrefinebio
>>> files = pyrefinebio.ComputedFile.search(is_compendia=True, is_public=True)
download(path, prompt=True)

Download a ComputedFile

Returns:

ComputedFile

Parameters:
  • path (str) – the path that the ComputedFile should be downloaded to

  • prompt (bool) – if true, will prompt before downloading files bigger than 1GB

extract()

Extract a downloaded ComputedFile

Returns:

ComputedFile

classmethod get(id)

Retrieve a specific ComputedFile based on id

Returns:

ComputedFile

Parameters:

id (int) – the id for the ComputedFile you want to get

classmethod search(**kwargs)

Retrieve a list of a ComputedFiles based on filters

Returns:

list of ComputedFile

Keyword Arguments:
  • id (int) – filter based on the id of the ComputedFile

  • samples (str) – filter based on the accession code for Samples related to the ComputedFile

  • is_qn_target (bool) – filter based on if the ComputedFile is a qn target

  • is_smashable (bool) – filter based on if the ComputedFile can be added to a normalized Dataset

  • is_qc (bool) – filter based on if the ComputedFile contains data about the quality control of a result rather than data about the result itself

  • is_compendia (bool) – filter based on if the ComputedFile is part of a compendium

  • quant_sf_only (bool) – filter based on if the Samples associated with the ComputedFile are RNA-seq only

  • svd_algorithm (str) – filter based on the SVD algorithm used for the ComputedFile

  • compendium_version (int) – filter based on the compendium version of the ComputedFile

  • created_at (str) – filter based on the time that the ComputedFile was created

  • last_modified (str) – filter based on the time that the ComputedFile was last modified

  • result__id (int) – filter based on the id of the ComputationalResult associated with the ComputedFile

  • ordering (str) – which field to use when ordering the results

  • limit (int) – number of results to return per page

  • offset (int) – the initial index from which to return the results