#!/usr/bin/env python # coding: utf-8 # # T cell annotations # # In this notebook, we upload cell type annotations assigned by our domain experts. These annotations were generated using markers and by interactive investigation of our .h5ad files. # # As these are derived from our .h5ad files, we'll connect them to the HISE analysis chain by chaching those files and using `hisepy.upload.upload_files()`. # In[1]: import hisepy from datetime import date # For T cells, this was done in multiple steps. First, we clustered all T cells, then we used these original clusters to identify several T cell subsets for iterative clustering. # # Here, we'll combine these steps to build the link in our reproducibility chain. # In[2]: in_files = [ '70651e60-282b-4ed0-96f6-414547297232', # Naive CD4 T cell .h5ad '1ad9302d-6fd5-49b0-be4c-8a08492c7cb7', # MAIT CD8 T cell .h5ad '6c1dff43-ddc5-437b-8e3d-dd5a32553b16', # CM CD8 T cell .h5ad 'b671c53a-2698-41c1-a886-9ab939306716', # EM CD8 T cell .h5ad '35b11bcf-7a45-4714-b470-9f7627d6fbbd', # Treg cell .h5ad '5ae29893-5a77-4081-86d1-523713a237e6', # Naive CD8 T cell .h5ad '90a71622-5713-47f7-82e8-18e164ca9454', # Proliferating T cell .h5ad 'e5ec7efd-a210-4b98-9f45-f95ab5e6cc83', # gdT cell .h5ad 'd33ef147-59db-4fb6-950c-1dd8af242d4f', # ISG-high T cell .h5ad 'a04b6a89-81ff-43ca-b0f8-0b1939f407f1' # Other T cell .h5ad ] hise_res = hisepy.reader.cache_files(in_files) # In[8]: out_files = [ 'annotations/pbmc_ref_t-cd4-naive_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-mait_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-cd8-cm_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-cd8-em_annotations_2024-03-05.csv', 'annotations/pbmc_ref_treg_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-cd8-naive_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-proliferating_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-gd_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-isg-high_annotations_2024-03-05.csv', 'annotations/pbmc_ref_t-other_annotations_2024-03-05.csv' ] # In[9]: study_space_uuid = '64097865-486d-43b3-8f94-74994e0a72e0' title = 'T annotations {d}'.format(d = date.today()) # In[10]: hisepy.upload.upload_files( files = out_files, study_space_id = study_space_uuid, title = title, input_file_ids = in_files ) # In[11]: import session_info session_info.show() # In[ ]: