GRichard513 commited on
Commit ·
b6b01c8
1
Parent(s): a815b7e
feat: add option to load specific file
Browse filesFiles changed (4)
225 unmodified lines2262272282292302315 unmodified lines23723823924024124224324424524624724844 unmodified lines293294295296297298299300301225 unmodified linesself,sequence_length: int = DEFAULT_LENGTH,filter_out_sequence_length: int = DEFAULT_FILTER_OUT_LENGTH,**kwargs,):"""5 unmodified linescoordinate_csv_file: The csv file that stores the coordinates and filename of the targetlabels_csv_file: The csv file that stores the labels with one sample per row.sequence_length: Sequence length for this handler."""self.reference_genome = Noneself.coordinate_csv_file = Noneself.labels_csv_file = Noneself.sequence_length = sequence_lengthself.filter_out_sequence_length = filter_out_sequence_lengthif filter_out_sequence_length is not None:assert isinstance(filter_out_sequence_length, int)44 unmodified lines)self.reference_genome = Fasta(reference_genome_file, one_based_attributes=False)self.df_csv_file = dl_manager.download_and_extract("transcript_expression/GTEx_final_tpm_multiomics.csv")return super().split_generators(dl_manager, cache_dir_root)225 unmodified lines2262272282292302312325 unmodified lines23823924024124224324424524624724824925025125244 unmodified lines297298299300301302303304305306307308309310311312313314225 unmodified linesself,sequence_length: int = DEFAULT_LENGTH,filter_out_sequence_length: int = DEFAULT_FILTER_OUT_LENGTH,expression_method: str = "read_counts_old",**kwargs,):"""5 unmodified linescoordinate_csv_file: The csv file that stores the coordinates and filename of the targetlabels_csv_file: The csv file that stores the labels with one sample per row.sequence_length: Sequence length for this handler.expression_method: To specify if user wants to use TPMs instead of readcounts."""self.reference_genome = Noneself.coordinate_csv_file = Noneself.labels_csv_file = Noneself.sequence_length = sequence_lengthself.filter_out_sequence_length = filter_out_sequence_lengthself.expression_method = expression_methodif filter_out_sequence_length is not None:assert isinstance(filter_out_sequence_length, int)44 unmodified lines)self.reference_genome = Fasta(reference_genome_file, one_based_attributes=False)if self.expression_method == "tpm":self.df_csv_file = dl_manager.download_and_extract("transcript_expression/GTEx_final_tpm_multiomics.csv")elif self.expression_method == "read_counts_old":self.df_csv_file = dl_manager.download_and_extract("transcript_expression/GTEX_v1_multiomics.csv")elif self.expression_method == "read_counts":raise NotImplementedError("Needs the dataset")return super().split_generators(dl_manager, cache_dir_root)
123version https://git-lfs.github.com/spec/v1oid sha256:c26aac2b9f4f1ab97f800337a36294c3cc99eb18c16ad7e99967183b43810908size 446177061123version https://git-lfs.github.com/spec/v1oid sha256:33497cd1e5ace0eee4f220319dd16bfa5b9b0befae9c6fa95b8abc3d62f5e1fcsize 457970509123version https://git-lfs.github.com/spec/v1oid sha256:a188b731d7e9ec28ac8dd723d4d0bee597bbd4f8b4ba78707875e7a868ed778asize 539601860multi_omics_transcript_expression.py+16-3
transcript_expression/GTEx_tpm_multiomics.csvDeleted-3
transcript_expression/expression_values_v1.csvDeleted-3
transcript_expression/expression_values_v2.csvDeleted-3