Instructions to use silicobio/hoike with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use silicobio/hoike with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("silicobio/hoike", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
| license: cc-by-nc-2.0 | |
| library_name: diffusers | |
| tags: | |
| - transcriptomics | |
| - bioinformatics | |
| - gene-expression | |
| - genomics | |
| datasets: | |
| - silicobio/hoike_normal_expression_GTEx_Analysis_v10_log2tpmplus1 | |
| - silicobio/hoike_condition_expression_TCGA_various_log2tpmplus1 | |
| # Hōʻike: A Joint-Embedding Predictive Architecture for Transcriptome Data Generation with Diffusion Models | |
| <h3 align="right">Silico Biosciences</h3> | |
| Visit the GitHub repository for the full framework code: https://github.com/silicobio/hoike | |
| ## Usage | |
| ```py | |
| ## 1. Look up the condition samples for a tissue that exists in the normal reference set. | |
| user_target_tissue = "Skin" | |
| condition_subset = dataset.condition_df[dataset.condition_df["tissue_type"] == user_target_tissue].reset_index(drop=True) | |
| normal_baseline_array = dataset.normal_profiles[user_target_tissue] | |
| ## 2. Generate with sampling-time normalization consistent with diffusion training. | |
| generated_df = generate_synthetic_condition_data_consistent( | |
| normal_profile=normal_baseline_array, | |
| jepa=jepa_model, | |
| diffusion=diff_model, | |
| scheduler=scheduler, | |
| gene_cols=dataset.gene_cols, | |
| num_samples=2500, | |
| value_cap=condition_value_cap, | |
| sampling_noise_scale=1.1, | |
| ) | |
| ``` |