### Run Polaris Setup Script Source: https://github.com/ai4nucleome/polaris/blob/master/doc/README.md Execute the setup script provided with the Polaris repository. This script automates the installation process and downloads necessary model weights from Hugging Face. ```bash ./setup.sh ``` -------------------------------- ### Download Example .bcool File Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Demonstrates how to download an example .bcool file (a type of .mcool) from a Hugging Face repository using `wget`. This file can be used to test Polaris loop annotation methods. The command is shown within a %%bash cell, indicating it's intended for execution in an environment like a Jupyter notebook. ```bash wget https://huggingface.co/rr-ss/Polaris/resolve/main/example/loop_annotation/GM12878_250M.bcool?download=true -O "./GM12878_250M.bcool" ``` -------------------------------- ### Download Example Data with Wget (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/README.md Downloads the example .bcool data file for loop prediction from the Hugging Face repository using the wget command-line utility. ```bash wget https://huggingface.co/rr-ss/Polaris/resolve/main/example/loop_annotation/GM12878_250M.bcool?download=true -O "./loop_annotation/GM12878_250M.bcool" ``` -------------------------------- ### Install Polaris using Git and Conda Source: https://github.com/ai4nucleome/polaris/blob/master/doc/README.md These commands guide the user through cloning the Polaris repository from GitHub and setting up a dedicated Python 3.9 virtual environment using Conda, which is recommended for managing dependencies. ```bash git clone https://github.com/ai4nucleome/Polaris.git cd Polaris conda create -n polaris python=3.9 conda activate polaris ``` -------------------------------- ### Install cooler Python Library Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Provides the command to install the `cooler` Python library using pip, which is required for converting Hi-C data formats to .mcool. ```bash pip install cooler ``` -------------------------------- ### Displaying Polaris Util Subcommand Help (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/CLI_walkthrough.ipynb Shows how to get detailed help and options for the 'util' subcommand of the Polaris CLI. ```bash polaris util --help ``` -------------------------------- ### Displaying Polaris CLI Help (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/CLI_walkthrough.ipynb Shows how to get the main help message for the Polaris command line interface, listing available subcommands and general options. ```bash polaris --help ``` -------------------------------- ### Displaying Polaris Loop Subcommand Help (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/CLI_walkthrough.ipynb Shows how to get detailed help and options for the 'loop' subcommand of the Polaris CLI. ```bash polaris loop --help ``` -------------------------------- ### Predict Loops with Polaris (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/README.md Runs the Polaris loop pred command to predict loops on specified chromosomes (chr15, chr16, chr17) using the downloaded .bcool input file and saves the output to a .bedpe file. ```bash polaris loop pred --chrom chr15,chr16,chr17 -i ./loop_annotation/GM12878_250M.bcool -o ./loop_annotation/GM12878_250M_chr151617_loops.bedpe ``` -------------------------------- ### Perform APA with Polaris (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/README.md Executes the Polaris util pileup command to perform Aggregated Peak Analysis (APA) on the predicted loops, saving the resulting pileup image and enabling the p2ll option. It uses the predicted loops .bedpe file and the original .bcool data. ```bash polaris util pileup --savefig ./APA/GM12878_250M_chr151617_loops.pileup.png --p2ll True ./loop_annotation/GM12878_250M_chr151617_loops.bedpe ./loop_annotation/GM12878_250M.bcool ``` -------------------------------- ### View Polaris Command-Line Help Source: https://github.com/ai4nucleome/polaris/blob/master/doc/README.md Use this command to display the detailed help message for the Polaris command-line interface, providing information on available commands, options, and parameters. ```bash polaris --help ``` -------------------------------- ### Generate Multiresolution .mcool using cooler Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Provides the `cooler zoomify` command to convert a single-resolution .cool file into a multiresolution .mcool file, which is the required input format for Polaris. ```bash cooler zoomify ``` -------------------------------- ### Display Help for polaris loop scorelf Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Shows how to display the help message for the `polaris loop scorelf` function, which is under development for handling very large files. The command is shown within a %%bash cell. ```bash polaris loop scorelf --help ``` -------------------------------- ### Call Loops using polaris loop pool (Method 2, Step 2) Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Shows the command for the second step of the two-step method: calling loops by clustering from the previously generated loop score file using `polaris loop pool`. It specifies the input score file, output .bedpe for loops, and a threshold. The command is shown within a %%bash cell. ```bash polaris loop pool -i GM12878_250M_chr151617_loop_score.bedpe -o GM12878_250M_chr151617_loops_method2.bedpe -t 0.5 ``` -------------------------------- ### Run Polaris Loop Prediction Source: https://github.com/ai4nucleome/polaris/blob/master/doc/README.md This command demonstrates a quick run of the loop prediction function at 5kb resolution. It requires specifying the input contact map file (e.g., .mcool) and the desired output path for the results. ```bash polaris loop pred -i [input.mcool] -o [output_path] ``` -------------------------------- ### Predict Loops using polaris loop pred (Method 1) Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Shows the command for the direct single-step loop prediction method using `polaris loop pred`. It specifies chromosomes to process, the input .mcool file, the output .bedpe file, and a threshold. Notes on handling CUDA memory errors are relevant context. The command is shown within a %%bash cell. ```bash polaris loop pred -c chr15,chr16,chr17 -i GM12878_250M.bcool -o GM12878_250M_chr151617_loops.bedpe -t 0.5 ``` -------------------------------- ### Generate Loop Scores using polaris loop score (Method 2, Step 1) Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Provides the command for the first step of the two-step method: generating loop scores for each pixel using `polaris loop score`. It specifies chromosomes, input .mcool, output .bedpe for scores, and a threshold. The command is shown within a %%bash cell. ```bash polaris loop score -c chr15,chr16,chr17 -i GM12878_250M.bcool -o GM12878_250M_chr151617_loop_score.bedpe -t 0.5 ``` -------------------------------- ### Convert .pairs to .cool using cooler Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Shows the `cooler cload pairs` command to convert a .pairs file into a single-resolution .cool file. It requires specifying the genome assembly, column names for chromosome and position, input pairs file, and desired resolution. ```bash cooler cload pairs --assembly -c1 chrom1 -p1 pos1 -c2 chrom2 -p2 pos2 .cool ``` -------------------------------- ### Generate Scores and Call Loops for Large Files (Under Development) Source: https://github.com/ai4nucleome/polaris/blob/master/example/loop_annotation/loop_annotation.ipynb Provides the sequence of commands using `polaris loop scorelf` and `polaris loop pool` for processing very large .mcool files. `loop scorelf` is a function under development specifically for this purpose. The commands are shown within a %%bash cell. ```bash polaris loop scorelf -c chr15,chr16,chr17 -i GM12878_250M.bcool -o GM12878_250M_chr151617_loop_score.bedpe -t 0.5 polaris loop pool -i GM12878_250M_chr151617_loop_score.bedpe -o GM12878_250M_chr151617_loops_method2.bedpe -t 0.5 ``` -------------------------------- ### Perform APA Pileup using Polaris (Bash) Source: https://github.com/ai4nucleome/polaris/blob/master/example/APA/APA_example.ipynb This command utilizes the `polaris util pileup` function to generate an Aggregated Peak Analysis (APA) plot from Polaris loop detection results. It takes a BEDPE file containing loop coordinates and a .bcool file (likely a cooler file) as input, saving the resulting pileup image to a specified PNG file. The `--p2ll True` flag likely controls some aspect of the plotting or data processing. ```bash %%bash polaris util pileup --savefig "./GM12878_250M_chr151617_loops.pileup.png" --p2ll True "../loop_annotation/GM12878_250M_chr151617_loops.bedpe" "../loop_annotation/GM12878_250M.bcool" ``` -------------------------------- ### BibTeX Citation for Polaris Source: https://github.com/ai4nucleome/polaris/blob/master/README.md This snippet provides the BibTeX entry for citing the Polaris paper published in bioRxiv. It includes standard fields like title, author, journal, and year, suitable for inclusion in academic bibliographies. ```BibTeX @article {Hou2024Polaris, title = {A versatile tool for chromatin loop annotation in bulk and single-cell Hi-C data}, author = {Yusen Hou, Audrey Baguette, Mathieu Blanchette, and Yanlin Zhang}, journal = {bioRxiv} year = {2024}, } ``` -------------------------------- ### BibTeX Citation for Polaris Source: https://github.com/ai4nucleome/polaris/blob/master/doc/README.md This is the recommended BibTeX entry for citing the Polaris paper in academic publications. It includes authors, title, journal (bioRxiv), and year. ```bibtex @article {Hou2024Polaris, title = {A versatile tool for chromatin loop annotation in bulk and single-cell Hi-C data}, author = {Yusen Hou, Audrey Baguette, Mathieu Blanchette, and Yanlin Zhang}, journal = {bioRxiv} year = {2024}, } ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.