Created
November 26, 2021 13:05
-
-
Save prasad-kumkar/3731dbed9eb2b850b50e4cbcc85041e4 to your computer and use it in GitHub Desktop.
Genomics_Project.ipynb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "nbformat": 4, | |
| "nbformat_minor": 0, | |
| "metadata": { | |
| "colab": { | |
| "name": "Genomics_Project.ipynb", | |
| "provenance": [], | |
| "authorship_tag": "ABX9TyPkjt1RPFdmdtxujoQ4nC85", | |
| "include_colab_link": true | |
| }, | |
| "kernelspec": { | |
| "name": "python3", | |
| "display_name": "Python 3" | |
| } | |
| }, | |
| "cells": [ | |
| { | |
| "cell_type": "markdown", | |
| "metadata": { | |
| "id": "view-in-github", | |
| "colab_type": "text" | |
| }, | |
| "source": [ | |
| "<a href=\"https://colab.research.google.com/gist/prasad-kumkar/3731dbed9eb2b850b50e4cbcc85041e4/genomics_project.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>" | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "gF5D5Rpxg659", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "caa09c3a-82ec-420e-d11b-40a9e7409b39" | |
| }, | |
| "source": [ | |
| "from google.colab import drive\n", | |
| "drive.mount('/content/drive')" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "Mounted at /content/drive\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "UYo2H6S-h540", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "cb4c3655-0622-4a26-97ce-3e19377afce2" | |
| }, | |
| "source": [ | |
| "!ls \"/content/drive/My Drive/Colab Notebooks\"" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "baseline_on_sequence.py helper_with_N.py test_testing.txt\n", | |
| "baselines_output\t helper_with_N.pyc Untitled\n", | |
| "data\t\t\t merge_and_retrain.py Untitled0.ipynb\n", | |
| "Deep_Q_Network_Solution.ipynb n-mer_freq.py\t Untitled1.ipynb\n", | |
| "dqn\t\t\t output_folder\t Untitled2.ipynb\n", | |
| "final_freq\t\t pattern_branch.py Untitled3.ipynb\n", | |
| "final_pattern\t\t predict_only.py\t Untitled4.ipynb\n", | |
| "final_ViraMiner\t\t README.md\t ViraMiner_end2end.py\n", | |
| "frequency_branch.py\t test_output.txt\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "yOeXBGWYh8_0", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "37d3af3c-469d-4519-9d7c-ca502399e850" | |
| }, | |
| "source": [ | |
| "!python2 /content/drive/My\\ Drive/Colab\\ Notebooks/frequency_branch.py /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_model_name --input_path /content/drive/My\\ Drive/Colab\\ Notebooks/data/DNA_data/fullset --epochs 10 --filter_size 8 --layer_sizes 800 --dropout 0.1 --learning_rate 0.001 --lr_decay None > /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_logfile.txt" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "Using TensorFlow backend.\n", | |
| "2020-11-01 22:43:26.426404: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcuda.so.1\n", | |
| "2020-11-01 22:43:26.491492: E tensorflow/stream_executor/cuda/cuda_driver.cc:351] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected\n", | |
| "2020-11-01 22:43:26.491550: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (5d69b9e2c8ea): /proc/driver/nvidia/version does not exist\n", | |
| "2020-11-01 22:43:26.503360: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2200000000 Hz\n", | |
| "2020-11-01 22:43:26.503650: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x56344ebfaa00 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| "2020-11-01 22:43:26.503693: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "qYQhaETIo3SM", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "df27ae06-d39f-45bc-ab0c-1ff203431778" | |
| }, | |
| "source": [ | |
| "!python2 /content/drive/My\\ Drive/Colab\\ Notebooks/pattern_branch.py /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_model_name_pattern --input_path /content/drive/My\\ Drive/Colab\\ Notebooks/data/DNA_data/fullset --epochs 10 --filter_size 8 --layer_sizes 800 --dropout 0.1 --learning_rate 0.001 --lr_decay None > /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_logfile_pattern.txt" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "Using TensorFlow backend.\n", | |
| "2020-11-02 00:36:50.478848: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcuda.so.1\n", | |
| "2020-11-02 00:36:50.488776: E tensorflow/stream_executor/cuda/cuda_driver.cc:351] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected\n", | |
| "2020-11-02 00:36:50.488840: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (5d69b9e2c8ea): /proc/driver/nvidia/version does not exist\n", | |
| "2020-11-02 00:36:50.494728: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2200000000 Hz\n", | |
| "2020-11-02 00:36:50.495107: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x559307794a00 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| "2020-11-02 00:36:50.495148: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n", | |
| "Traceback (most recent call last):\n", | |
| " File \"/content/drive/My Drive/Colab Notebooks/pattern_branch.py\", line 153, in <module>\n", | |
| " pred_probas = model.predict_generator(generate_batches_from_file(args.input_path+\"_validation.csv\",args.batch_size), steps=val_steps_per_epoch+1,workers=1, use_multiprocessing=False)\n", | |
| "NameError: name 'val_steps_per_epoch' is not defined\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "-e_MUp44s0OR", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "92b2cadc-2873-4bf8-bb1b-290612aa8179" | |
| }, | |
| "source": [ | |
| "!python2 /content/drive/My\\ Drive/Colab\\ Notebooks/merge_and_retrain.py /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_model_name_final --input_path /content/drive/My\\ Drive/Colab\\ Notebooks/data/DNA_data/fullset --pattern_model /content/drive/My\\ Drive/Colab\\ Notebooks/final_freq/pattern_model.hdf5 --freq_model /content/drive/My\\ Drive/Colab\\ Notebooks/final_freq/frequency_model.hdf5 --finetuning True --epochs 10 --dropout 0.1 --learning_rate 0.001 --lr_decay None > /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_logfile_final.txt" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "Using TensorFlow backend.\n", | |
| "2020-11-02 03:03:08.079942: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcuda.so.1\n", | |
| "2020-11-02 03:03:08.089492: E tensorflow/stream_executor/cuda/cuda_driver.cc:351] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected\n", | |
| "2020-11-02 03:03:08.089546: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (5d69b9e2c8ea): /proc/driver/nvidia/version does not exist\n", | |
| "2020-11-02 03:03:08.095511: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2200000000 Hz\n", | |
| "2020-11-02 03:03:08.095787: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x55ea5d3a8840 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| "2020-11-02 03:03:08.095827: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "Y2huCnHz5GUb", | |
| "colab": { | |
| "base_uri": "https://localhost:8080/" | |
| }, | |
| "outputId": "58bd841d-48b5-4692-cb4f-abd8e1b7ac28" | |
| }, | |
| "source": [ | |
| "!python2 /content/drive/My\\ Drive/Colab\\ Notebooks/predict_only.py --input_file /content/drive/My\\ Drive/Colab\\ Notebooks/data/DNA_data/fullset_test.csv --model_path /content/drive/My\\ Drive/Colab\\ Notebooks/output_folder/output_model_name_final_afterFT.hdf5 > /content/drive/My\\ Drive/Colab\\ Notebooks/test_testing.txt\n", | |
| "\n" | |
| ], | |
| "execution_count": null, | |
| "outputs": [ | |
| { | |
| "output_type": "stream", | |
| "text": [ | |
| "Using TensorFlow backend.\n", | |
| "2020-11-02 08:51:35.062835: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libcuda.so.1\n", | |
| "2020-11-02 08:51:35.072233: E tensorflow/stream_executor/cuda/cuda_driver.cc:351] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected\n", | |
| "2020-11-02 08:51:35.072288: I tensorflow/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (5d69b9e2c8ea): /proc/driver/nvidia/version does not exist\n", | |
| "2020-11-02 08:51:35.078011: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency: 2200000000 Hz\n", | |
| "2020-11-02 08:51:35.078327: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x55e9e43a2840 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", | |
| "2020-11-02 08:51:35.078368: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n" | |
| ], | |
| "name": "stdout" | |
| } | |
| ] | |
| }, | |
| { | |
| "cell_type": "code", | |
| "metadata": { | |
| "id": "GW2cCHDpJVgm" | |
| }, | |
| "source": [ | |
| "" | |
| ], | |
| "execution_count": null, | |
| "outputs": [] | |
| } | |
| ] | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment