sha256
stringlengths
64
64
language
stringclasses
28 values
size
int32
1
491k
lines
int32
1
23.2k
content
stringlengths
1
200k
65da09ef017d153aa52f27cc8c8c228145b1803d8851b4c046b6476aef02f30d
Jupyter
27,011
633
# %% [markdown] # # Experiments with `aihwkit` # ## Exploring the sensitivity of analog inference, analog-aware retraining and in-analog training to the non-idealities of Analog Crossbars # # In-memory computing uses crossbar arrays of non-volatile memories to perform Vector-Matrix Multiplications (VMMs) in-situ, i.e....
e17f30dfe56043605f1e144627970345773f3c4505bae6f386192db3d2f6dd34
Jupyter
27,214
917
# %% import argparse import os import numpy as np import math import torchvision.transforms as transforms from torchvision.utils import save_image from torch.utils.data import DataLoader from torchvision import datasets from torch.autograd import Variable import torch.nn as nn import torch.nn.functional as F import ...
48f3152a54d7fd5f23745a5f2254e014178aa2c4a2afbd26c087eadd74028006
Jupyter
27,215
497
# %% #import packages from skimage.io import imread, imsave from skimage.transform import rescale from skimage.exposure import rescale_intensity from shapely.geometry import MultiPolygon, Polygon from collections import defaultdict import geopandas import pandas as pd import cv2 import numpy as np import json import ...
2e20120cc4c7f54b01a5c8643795de410fbcf0f940fa46be1ea08b6f62de6e87
Jupyter
27,339
767
# %% [markdown] # # LERCause: Causal Sentence Identification with LER (Nuclear Safety Reports) # # This code is to run traditional machine learning models on LER data for sentence classification and prediction. # # Author: # 1. Jinmo Kim: School of Information Sciences, University of Illinois Urbana-Champaign ...
756b9783e1906c58699b160be7d6213081628ae96584d8dd4873fbee3d4d6db6
Jupyter
27,366
673
# %% [markdown] # # Train a GPT-2 model with Ray Train `JaxTrainer` # # **Time to complete**: 15 min # # This template shows you how to distribute a JAX/Flax training loop with [Ray Train](https://docs.ray.io/en/latest/train/train.html)'s `JaxTrainer`. You’ll train a small GPT-2-style Transformer from scratch on the ...
0ce3d8b21cd4ba26d0888080aa3b7522f9539adb0a1527669af275450fc7fa78
Jupyter
27,703
1,162
# %% %load_ext autoreload %autoreload 2 # %% import platform import random import string import uuid import math import os import os.path import skimage import sak import sak.signal.wavelet import sak.data import sak.data.augmentation import sak.data.preprocessing import numpy as np import scipy as sp import scipy.sig...
b0abc92584fd720c73bedd72ecbe195efc1146b267fa6171b9f06b9d080d770e
Jupyter
27,991
741
# %% """ This script fine-tunes the Conformer project (https://github.com/eeyhsong/EEG-Conformer) and achieves better experimental results compared to the previous project. fine-tunes by author: zhaowei701@163.com """ import os gpus = [1] os.environ['CUDA_DEVICE_ORDER'] = 'PCI_BUS_ID' os.environ["CUDA_VISIBLE_DEVIC...
a92c64dcb5d224244ec45d07c2207b42085ccac4692bd1693175af098ded3382
Jupyter
28,046
978
# %% !pip install google-colab-selenium # %% import multiprocessing import tqdm import numpy as np import scipy.stats as st import scipy import numba import math from bokeh.io import export_svg from google_colab_selenium import Chrome #import biocircuits # Plotting modules import bokeh.io import bokeh.plotting fro...
54578596c7dd99603f0d6ee43323f06e87aa2a5a47b5feec1dfd8d6e041ae7ad
Jupyter
28,192
886
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import pathlib import glob import shutil import uuid import random import platform import torch import torchvision impor...
ae4cf54e59068395b0895f8c392fa876dcc15678fbeecb9f491ad14614b9ac30
Jupyter
28,285
767
# %% %load_ext autoreload %autoreload 2 # %% import platform import random import uuid import os import os.path import skimage import sak import sak.signal.wavelet import sak.data import sak.data.augmentation import numpy as np import scipy as sp import scipy.signal import pandas as pd import networkx import networkx....
3541202d743aac4fca3be5efdade217e7444d18e29eb550049ed26f713462dac
Jupyter
28,434
822
# %% %load_ext autoreload %autoreload 2 # %% %matplotlib inline import numpy import random import time import sys import os import tifffile import io import pickle import matplotlib import yaml from matplotlib import pyplot from PIL import Image from tqdm.auto import trange from skimage import filters from collecti...
a1447b580d415ef519c11ba2df6fb7108b9c212eb043097af3b34b3957930712
Jupyter
28,723
622
# %% import os import math import time import operator from collections import defaultdict import numpy as np import pandas as pd from scipy import stats from sklearn.linear_model import LogisticRegression, LinearRegression, ElasticNet, Ridge from sklearn.metrics import roc_curve, auc, precision_recall_curve, average_...
1dde383e2a05b54931ac01714f3d711ad0fac0e7bc87dc5b87a9a9a8d59ede7e
Jupyter
28,835
939
# %% [markdown] # # Fit to observed # %% [markdown] # ## Using the only the density map output # %% [markdown] # ### Loading model # %% import torch import torch.nn as nn from modelsImplementation import CerealNet # Check if CUDA (GPU) is available device = torch.device("cuda" if torch.cuda.is_available() else "cpu...
121a51b4e5828268e39aea27830ad70d096f6b4664e94651e447df7751819dda
Jupyter
28,926
975
# %% import numpy as np import pandas as pd import os import torch from torch.autograd import Variable from matplotlib import pyplot as plt %matplotlib inline # %% import sys sys.path.append("../Network-SDE-Inference/utils") import NeuGNN_model import Self_func import Interaction_func from NeuGNN_model import * from S...
c179b956f40c2cfd194d6541a9d6958a6824b65ff995f9097e434d153eb75b43
Jupyter
28,975
787
# %% [markdown] # # Providing custom stimuli # # Follow this notebook to learn how to use our models for generating hypothesis about neural computations with custom stimuli. # %% [markdown] # **Select GPU runtime** # # To run the notebook on a GPU select Menu -> Runtime -> Change runtime type -> GPU. # %% # @markdo...
fcc027d31454131dd96b67a10d7c0c345ef28e44fca9eec678a5556339264f0b
Jupyter
29,011
778
# %% """ CTNet: A Convolution-Transformer Network for EEG-Based Motor Imagery Classification author: zhaowei701@163.com """ import os gpus = [0] os.environ['CUDA_DEVICE_ORDER'] = 'PCI_BUS_ID' os.environ["CUDA_VISIBLE_DEVICES"] = '0' import numpy as np import pandas as pd import random import datetime import time fr...
d50b4a8b7b04c6aa4691c7a1f03be0f12b2372a7db57fda07ec7430d88f39a0d
Jupyter
29,093
934
# %% import numpy as np import pandas as pd import os import torch from torch.autograd import Variable from matplotlib import pyplot as plt %matplotlib inline # %% import sys sys.path.append("../Network-SDE-Inference/utils") import NeuGNN_model import Self_func import Interaction_func from NeuGNN_model import * from S...
e439f2bba8133a9ca1b4d564b0d944eca2e41870b3904b46d14c17f8bf6b7033
Jupyter
29,125
599
# %% [markdown] # # Tuning XGBoost hyperparameters with Ray Tune # # <a id="try-anyscale-quickstart-tune-xgboost" href="https://console.anyscale.com/register/ha?render_flow=ray&utm_source=ray_docs&utm_medium=docs&utm_campaign=tune-xgboost"> # <img src="../../_static/img/run-on-anyscale.svg" alt="try-anyscale-quick...
58f941994b6edc6a2e61e1c74d276b27d0910be92b3506b92b6595d1db0dd573
Jupyter
29,689
662
# %% path_project = "/media/concha-eloko/Linux/depolymerase_building" dir_out = f"{path_project}/seekfold_phagedepo" import pandas as pd import os path_info = f"/media/concha-eloko/Linux/depolymerase_building/depolymerase_fold.csv" info_df = pd.read_csv(path_info , sep = "\t", header = 0) dico_folds = {"jelly-roll" :...
51bd16ae2372a5bab09f5f39d5bbd7902e687852a3e20e319e494f3a58e29d13
Jupyter
29,800
1,029
# %% import numpy as np import pandas as pd import os import torch from torch.autograd import Variable from matplotlib import pyplot as plt %matplotlib inline # %% # %% import sys sys.path.append("../Network-SDE-Inference/utils") import NeuGNN_model import Self_func import Interaction_func from NeuGNN_model import *...
9afca56bd53076ea176eccdf183ab286ca14f783ac1da255f5561c71a4b9733c
Jupyter
29,967
677
# %% from endstate_correction.analysis import ( plot_overlap_for_equilibrium_free_energy, plot_results_for_equilibrium_free_energy, ) from endstate_correction.equ import calculate_u_kn import pathlib import endstate_correction from endstate_correction.system import create_charmm_system from openmm.app import Ch...
cb9d03b9143893f1f5bca59aea9825a3a23a2fa6c48860bfb9668a6866555e36
Jupyter
30,050
947
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import glob import shutil import uuid import random import platform import ecgdetectors import torch import torchvision ...
44c3c42385a4d27a7eb1a3e89ed9b3212d41a9af66514c904e934bc779e1bc46
Jupyter
30,200
612
# %% [markdown] # # Build the depolymerase database # *** # # ## The cookbook for building the depolymerase database : # ### A. Get the E.C associated with the depolymerase activity # ### B. Collect the IPR entries associated with the E.C of interest # ### C. Scan the interproscan descriptions ; keep those that are ...
440fedfc887dc3c6da9b48c8b091f7f1b0213ee5e4adc9dded2196f3a188e905
Jupyter
30,274
738
# %% [markdown] # # Quick Start With N-MNIST # # This tutorial explains all steps necessary to deploy a pretrained SNN to the devkit. # # 1. The pretrained SNN will be obtained by: # - CNN-to-SNN conversion. # - Train SNN with BPTT(Back Propagation Through Time) # # 2. As for the dataset, we use the ["N-MNI...
5387d4c005afe278a0dcc5451604158864b6b8cc07a778df49227e602f022982
Jupyter
30,424
802
# %% """ CTNet: A Convolution-Transformer Network for EEG-Based Motor Imagery Classification author: zhaowei701@163.com Due to memory constraints, the data augmentation method in LOSO classification was slightly optimized based on the approach used in subject-specific classification (main.py). Cite this work Zhao, ...
b323db3464f878be5cc264aa2025d8a1ff611274fc368033bdb380aac4956be9
Jupyter
31,078
825
# %% # %load_ext autoreload # %matplotlib widget # %% import numpy as np from pathlib import Path import pandas as pd import flammkuchen as fl import os from matplotlib import pyplot as plt from matplotlib.colors import LinearSegmentedColormap, Normalize import seaborn as sns from itertools import product from skimag...
4cdc9c7dff978681b182eba7d6624c73e69bd7eea1244a616c2a49c3d0fe1ed8
Jupyter
31,357
648
# %% [markdown] # ## Import all necessary packages to notebook # %% from sklearn.metrics import accuracy_score, f1_score, classification_report, confusion_matrix, roc_auc_score from sklearn.preprocessing import LabelEncoder import json import lightgbm as lgb import shap from IPython.display import clear_output ##### b...
e34272734869ba3ef50facc12aac521392302ccb7c5bfda6aa97577d980fe095
Jupyter
31,655
651
# %% [markdown] # ## Import all necessary packages to notebook # %% from sklearn.metrics import accuracy_score, f1_score, classification_report, confusion_matrix, roc_auc_score from sklearn.preprocessing import LabelEncoder import json from xgboost import XGBClassifier import shap from IPython.display import clear_out...
d66cefb093ca93dab05d3ae90e1562036492e82568356bf0c878e6c197fd39d4
Jupyter
32,020
713
# %% from google.colab import drive drive.mount("/content/drive") import os path="/content/drive/My Drive/AMP" os.chdir(path) os.listdir(path) # %% !sudo apt install python3.8 !update-alternatives --install /usr/local/bin/python3 python3 /usr/bin/python3.8 2 !update-alternatives --install /usr/local/bin/python3 python...
748d192b6303bb6362ea6d8252b2c195a8a0a217be8f3d998c3879be7f0448cd
Jupyter
32,054
675
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
74d4aeebf4d0102f997ac1e7d058d8a56130ba34a855eaa445f254c1e2da96b3
Jupyter
32,070
908
# %% [markdown] # # ECG Latent Space Exploration # This notebook shows how to create a latent space from a pretrained multimodal model. # %% import os import sys from typing import Callable, List, Dict import numpy as np import pandas as pd import matplotlib.pyplot as plt from sklearn.metrics import roc_auc_score from...
5671b7e22f3629613fcb1a3d19520a025132e204b1980a72973549198874f292
Jupyter
32,250
829
# %% import omicverse as ov from omicverse.utils import mde import scanpy as sc import scvelo as scv ov.utils.ov_plot_set() # %% adata=scv.datasets.dentategyrus() adata # %% adata.obs['celltype']=adata.obs['clusters'].copy() # %% import numpy as np import pandas as pd bulk=pd.read_csv('data/GSE74985_mergedCount.txt....
dbefe0efc1e7c33a2e27aac1e84f68af295794f5238cf707f214157c37469cf8
Jupyter
32,556
516
# %% [markdown] # <img src="img/standardized-team4.jpg" width=1400 /> # %% [markdown] # # A standardized framework to test event-based experiments: A tutorial # In the past decade, there has been a growing interest in improving scientific practices. Researchers have been enhancing their application of statistical test...
60ab4bc525968f09ad6d46890e5dde2fa7088852b24dd41ebcb92c00f368ae7b
Jupyter
32,878
841
# %% [markdown] # In this Jupyter notebook we showcase evolutionary IB-LGCA, i.e. we look at proliferating cells, where daughter cells inherit properties of mother cells plus a noise term. This idea is applied to two different models of cell proliferation and invasion and key aspects are highlighted with the help of co...
1137bb518f691dd4e6b1089d33d64f7a25a363a661efad790c18caf38acf5635
Jupyter
32,883
885
# %% using Distributed addprocs(8); # %% @everywhere using PulseInputDDM, MAT using Flatten # %% x_joint = Vector(undef, 3); x_choice = Vector(undef, 3); # %% ratnames = ["B068","T034","T036","T063","T030", "T035","T011","B053", "T080","T103","E021"]; dt, n, cross = 1e-2, 53, false data_path = joinpath(abspath(joinp...
2eb92c60019d4a141191199c5ed84a105b7be454135408ee8b4498d95380c081
Jupyter
33,123
924
# %% %load_ext autoreload %autoreload 2 # %% import platform import random import uuid import os import os.path import skimage import sak import sak.signal.wavelet import sak.data import sak.data.augmentation import numpy as np import scipy as sp import scipy.signal import pandas as pd import networkx import networkx....
66ae2680793364b97b7216624040211c863d8dabf1f0925cc66b68451fe46fea
Jupyter
33,175
817
# %% [markdown] # # Segmentation with `rising` and `PytorchLightning` # # This example will show you how to build a proper training pipeline with [PyTorch Lightning](https://github.com/PytorchLightning/pytorch-lightning) and [rising](https://github.com/PhoenixDL/rising). # But first let's configure this notebook corre...
98db6e9b87b7212b2c7488f204f2045adf6210f1378b0f4cebf55d8fe13a128e
Jupyter
33,304
970
# %% #%matplotlib widget import os from os import makedirs from pathlib import Path import numpy as np import pandas as pd import copy import matplotlib.pyplot as plt # %% directory = Path('../training_runs/selection_dir_comparison') os.listdir(directory) # %% run_paths = { '0.9': { 0: 'A2C_PongNoFrames...
8980d09a30cbe4e7728188b6634ab516f1e5a9aca78dc581f0ba39b5a8c62d64
Jupyter
33,410
1,184
{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Testing\n", "Script for testing basic functionalities that can be better examined visually. How to use: Run the notebook and look at the output." ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "##...
4a5559c2de7eed1e7ed2c558b6da07223f15acac6c2a670a2bbad7c64b798e2a
Jupyter
33,543
831
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import pathlib import glob import shutil import uuid import random import platform import torch import torchvision impor...
c65b516a09b8c8ee485f34f8fc688950df5a3b50a93fbf07d4d0420643fa8496
Jupyter
33,903
787
# %% import numpy as np from numpy.random import default_rng import torch import torch.nn.functional as F import pandas as pd import matplotlib.pyplot as plt from matplotlib.colors import TwoSlopeNorm from matplotlib.ticker import FuncFormatter from matplotlib.patches import Ellipse from sklearn.linear_model import Rid...
af18cc3733640456d088f9af27cd162e6a128e66d435ade4d8dd61c2611b319c
Jupyter
34,025
814
# %% import numpy as np from numpy.random import default_rng import torch import torch.nn.functional as F import pandas as pd import matplotlib.pyplot as plt from matplotlib.colors import TwoSlopeNorm from matplotlib.ticker import FuncFormatter from matplotlib.patches import Ellipse import matplotlib.transforms as tran...
db14129a0f25bd45c7b712d331a3a5b20bc14fd047a305d6200a79f2e49e8550
Jupyter
34,324
699
# %% import torch import torch.optim as optim from torch.utils.data import Dataset, DataLoader, SubsetRandomSampler, random_split import pandas as pd import numpy as np import os import random from collections import defaultdict, Counter from itertools import combinations import json import torch.nn as nn import torch....
dfef3068b9a983f06c5ba8acf745077e68a435774173e56aa38bfb308c447251
Jupyter
34,404
706
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
fce85b02d5e5896a051ca8447817af87d6cf8562ef3ac9971a01f7eae4297f44
Jupyter
34,633
859
# %% %load_ext autoreload %autoreload 2 # %% import platform import random import uuid import os import os.path import skimage import sak import sak.signal.wavelet import sak.data import sak.data.augmentation import numpy as np import scipy as sp import scipy.signal import pandas as pd import networkx import networkx....
fd0dfd7d72422ae6317b5dcd2d48ccdfd1de035ee5f910866784ad542bf9ba66
Jupyter
34,694
881
# %% import math from sklearn import metrics from sklearn import preprocessing import matplotlib.pyplot as plt import numpy as np import pandas as pd import re import time import datetime import random random.seed(1234) from scipy import interp import warnings warnings.filterwarnings("ignore") from collections import...
ef651045e5226038363c6dc739dec39e850a0d955a329369b04431f00a4c3a0e
Jupyter
34,702
1,094
# %% import sys import os from pathlib import Path module_path = '/usr/scratch/santis/weilenmc/repos' sys.path.append(module_path) os.chdir(module_path) import matplotlib.pyplot as plt import numpy as np import json import pickle import gym from gym.wrappers.monitoring.video_recorder import VideoRecorder import torc...
0c5e964494d18ce774e995d3130efc9fbead1c8c3efe95406e9a51ec1d709113
Jupyter
34,737
914
# %% import omicverse as ov from omicverse.utils import mde import scanpy as sc import scvelo as scv ov.utils.ov_plot_set() # %% adata=sc.read('data/liver_hpc_anno.h5ad',compression='gzip') adata # %% adata[adata.obs['celltype'].isin(['HPC','GMP','iNP','imNP','mNP','Monocyte','Basophil'])] # %% #['HPC','GMP','Erythr...
a81d2b2145af60a4749d69dd32a3d4232e8668384fb229ff672f3ae32737275e
Jupyter
34,873
710
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
0a704104bfcdc1b64ebaa96f4a3df3d89186418aee0489720b16c1bfe553a1a2
Jupyter
34,888
795
# %% [markdown] # # Examples from manuscript # # Code to run the examples reported in https://arxiv.org/abs/2009.01077 # %% from reval.best_nclust_cv import FindBestClustCV from reval.internal_baselines import select_best, evaluate_best from reval.visualization import plot_metrics from reval.utils import kuhn_munkres...
0a9cc1fc3a5cc461e90423a58c5cc0e0728a4d92dc106a1730a95fcfd86a96db
Jupyter
34,907
707
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
109b6ae6d0994e40bfd69f0b2508716f5310cfab651e2baaa6bf8401529594de
Jupyter
34,928
1,396
# %% import multiprocessing import tqdm import numpy as np import scipy.stats as st import scipy import numba import math #import biocircuits # Plotting modules import bokeh.io import bokeh.plotting from bokeh.models import LinearColorMapper, ColorBar #from bokeh.io import export_svgs bokeh.io.output_notebook() # ...
c085a09e571e17d6d38b96bfebf91faf9deadc918fdb21b5fe67cb9bcff7f72c
Jupyter
34,969
707
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
0ef8139799a8e658729e7be9c8a8e647571c1a1d2217c102ea1a9fe11ac4e10e
Jupyter
35,375
710
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
222b344715e4792924253c2df9cfe830ef776085d579e8f95a0962fabc17a772
Jupyter
35,430
707
# %% [markdown] # # Machine learning and deep learning methods applied to predicting customer status # # Purpose: Predict active and not active clients based on the proposed data structure and naive data structure. Here, we implemented Support Vector Machines (SVM), Random Forest (RF), K-nearest Neighbours (KNN) and L...
972f7d51de9629e4b361ca492d862dd8d0a6e0aba0b5f06b0bde9947652220a8
Jupyter
35,620
893
# %% [markdown] # # init # %% [markdown] # ## import package # %% import os import time from subprocess import call import numpy as np import pandas as pd import seaborn as sns from scipy import stats import seaborn as sns import matplotlib.pyplot as plt import scipy as sc from matplotlib.colors import ListedColorma...
4eac24b6b8fc93b6378f7f1db7343c1b7aa9892ae66842528e53acc3bfc9d006
Jupyter
36,086
895
# %% [markdown] # # Gaussian Processes # %% [markdown] # skorch supports integration with the fantastic [GPyTorch](https://gpytorch.ai/) library. GPyTorch implements various Gaussian Process (GP) techniques on top of PyTorch. # %% [markdown] # GPyTorch adopts many patterns from PyTorch, thus making it easy to pick up...
2f860ed2919e941683d535700f9ba202e8cebddaa159a6faf135d5556d5e181e
Jupyter
36,266
783
# %% import scanpy as sc from anndata import read_h5ad import pandas as pd import numpy as np import scipy as sp from statsmodels.stats.multitest import multipletests import matplotlib import matplotlib.pyplot as plt import seaborn as sns import os from os.path import join import gseapy as gp import statsmodels.api as ...
48a056f1e189792051ec9b339692a4c60c6913e51843affa72a77202854b20ff
Jupyter
36,305
941
# %% [markdown] # # Overview # %% [markdown] # The purpose of this notebook is to conduct batching for samples in preparation for the batched steps of the GATK-SV pipeline. # # This notebook performs hierarchical batching as described in the [batching documentation](https://broadinstitute.github.io/gatk-sv/docs/modu...
f930fd83bfb584b03040fbf93e0472ac1f8d5aa747ba1aeea37cd3efb8926c05
Jupyter
36,332
1,176
# %% import sys import os from pathlib import Path module_path = '/usr/scratch/santis/weilenmc/repos' sys.path.append(module_path) os.chdir(module_path) import matplotlib.pyplot as plt import numpy as np import json import pickle import gym from gym.wrappers.monitoring.video_recorder import VideoRecorder import torc...
59970d5c0f14fa3d566437307d693c2beeb455c50d8a12e69b78e0f6cf0188d1
Jupyter
36,455
1,122
# %% [markdown] # <h1>Table of Contents<span class="tocSkip"></span></h1> # <div class="toc"><ul class="toc-item"><li><span><a href="#环境配置" data-toc-modified-id="环境配置-1"><span class="toc-item-num">1&nbsp;&nbsp;</span>环境配置</a></span></li><li><span><a href="#全局参数设置" data-toc-modified-id="全局参数设置-2"><span class="toc-item-n...
91dbd969326735732773a314e3e270523185c7372fa0a731acb96c5e4fca1155
Jupyter
36,846
1,062
# %% [markdown] # # LERCause: Causal Sentence Identification with LER (Nuclear Safety Reports) # # This code is to run a CNN (Convolutional Neural Networks) model on LER data for sentence classification and prediction. # # Author: # 1. Jinmo Kim: School of Information Sciences, University of Illinoi...
a4839a97ed4ef9c64d3cdea6a12bd9197cdcc46354afc9b74d05d5c3f71813b3
Jupyter
36,881
1,134
# %% [markdown] # ## __XDF latency analysis of LSL data streams: Unity (triggered) vs EEG (measured)__ # ## Unity 2D project (simplest environment) vs heavy Unity 3D environment # # ### __Situation__ # #### Every 500ms a beep sound is played and the background color changes once one frame from black to white. # # ##...
e35a852bae3b0de596761229bd0cddd3108c5318ecbd48c1220775c7846f25d4
Jupyter
36,977
968
# %% import numpy as np import os import sys import nibabel as nib from pathlib import * import numpy as np from scipy import stats as stats import glob from scipy.special import xlogy import numpy as np import nibabel as nib #from nilearn import datasets, surface, plotting from sklearn.decomposition import PCA from sk...
79939bc99de12fb7b1ff0945e36f409a7229e5b4c9f030ad7b5f34364a2b66f5
Jupyter
37,300
909
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import pathlib import glob import shutil import uuid import random import platform import torch import torchvision impor...
cd2f8bc976d567d2497cec8e4be799d6a19d6d01bdd543836acf733a7aa034ed
Jupyter
37,372
882
# %% [markdown] # # Compare Cronbach's alpha to split-halves reliability # # # NOTE # -- # This part was run on Colab and it was for compatibility reasons as the package pingouin wasn't compatible with packages and versions used in the rest of the paper. # %% [markdown] # # Install all needed packages # # %% !pip ...
cfa874ffd5d9b697aaa53957c6684739fcadf67cd0193bed19f371572c9f1afa
Jupyter
37,580
964
# %% [markdown] # # *This file allows to generate all plots necessary for figures* # %% [markdown] # # **Useful packages and functions** # %% using DifferentialEquations, Plots, Polynomials, LaTeXStrings, ColorSchemes, DelimitedFiles, GraphPlot using Statistics, StatsPlots, Random, ProgressMeter, Printf, LinearAlgebr...
4c0eea2b406fe3e2cd82cd0fe8a08b43bdeb209bd02d84f7eacca25ea5a22ea3
Jupyter
37,595
1,064
# %% [markdown] # Code created together with Marc Vidal De Palol. # %% [markdown] # # Preprocessing: Unify the timestream and create all necessary dfs # %% # run to free up memory %reset # %% [markdown] # __Data Saved:__ # %% [markdown] # Important: participant 8 is saved in two files, they are combined as one in ...
2125961e18ef4fa372eba7797c59f647609586cd8a9ae1c3da7395def61d6c03
Jupyter
37,800
933
# %% %pip install davos import davos %conda install pytables davos.config.suppress_stdout = True # %% smuggle nltools as nlt # pip: nltools==0.4.7 smuggle nilearn as nl # pip: nilearn==0.10.0 smuggle nibabel as nib # pip: nibabel==5.0.1 smuggle datawrangler as dw # pip: pyd...
409e54a065ce5e87117f37cf11d7b8db042e06762b4844116cae2a0a675ef1c9
Jupyter
38,636
803
# %% import scanpy as sc from anndata import read_h5ad import pandas as pd import numpy as np import scipy as sp from statsmodels.stats.multitest import multipletests import statsmodels.api as sm import matplotlib.pyplot as plt import seaborn as sns import os from os.path import join import time from gprofiler import G...
2651894f572fe181f3db58eac17a072dee4d2765f675feb622bbdf7a83d3fc75
Jupyter
38,743
1,125
# %% [markdown] # # Fine-tuning on Pre-trained Model for Cell-type Annotation # In this tutorial, we demonstrate how to fine-tune a pre-trained model on a new dataset for the cell type annotation task. We use the Multiple Sclerosis dataset as an example and fine-tune on the pre-trained whole-body model. Please download...
c2d415e73c2006a822435ac6ff1adef075df5ad674753d5576e8c67f9d87701f
Jupyter
38,901
834
# %% [markdown] # # 10 Pre-process data # %% [markdown] # Collect data and store it in dataframes and dictionaries # %% [markdown] # ## List of dataframes # * `recordings` Basic data across all recordings from all dendrite # * `events` Measurements of all synaptic transmission events in the dataset # * `bursts` Summa...
0a97e76fb3bccf341a5e1735d410061acaa5443c40e4d301f8db6220376d910c
Jupyter
39,555
899
# %% [markdown] # ##### top # %% [markdown] # # This ntb is simply processing all the csv files and creating one csv per all conditions # # * [Unbiased C](#Unbiased-C) # * [Estimate C error per all combinations of N and n trials](#Estimate-C-error-per-all-combinations-of-N-and-n-trials) # * [estimate STD](#STD) # ...
f3ddb28df3511184a2195231aa9c82ca962cbb82775bb2607c9ed53f7a5b33dd
Jupyter
39,837
1,203
# %% import numpy as np import pandas as pd import os import torch from torch.autograd import Variable from matplotlib import pyplot as plt %matplotlib inline # %% import sys sys.path.append("../Network-SDE-Inference/utils") import NeuGNN_model import Self_func import Interaction_func from NeuGNN_model import * from S...
fd42541d29a682f933f7c5f9555a72859b08305044c216e1279f1abe4065c6b2
Jupyter
40,124
1,172
# %% # This Python 3 environment comes with many helpful analytics libraries installed # It is defined by the kaggle/python Docker image: https://github.com/kaggle/docker-python # For example, here's several helpful packages to load import numpy as np # linear algebra import pandas as pd # data processing, CSV f...
43fd7fdbe2b9401ea8fde423df80dc5f62df385c120a449c917626580f868aa5
Jupyter
40,314
1,028
# %% [markdown] # # *This file allows to generate all plots necessary for figures* # %% [markdown] # # **Useful packages and functions** # %% using DifferentialEquations, Plots, Polynomials, LaTeXStrings, ColorSchemes, DelimitedFiles, GraphPlot using Statistics, StatsPlots, Random, ProgressMeter, Printf, LinearAlgebr...
919a8695006582e503cf77b5be6ac2798634be565ef291e2a919dbdb8b8f1905
Jupyter
40,476
941
# %% [markdown] # ##### top # %% [markdown] # # This ntb analyses the Face memory perception task # # We have decided that we want to have the following measures for each participant: # # For each task (**p**erception, **b**lank, **f**aces, **em**otions) and for each difficulty level (24, 30, 36) we want to have the...
eb58a893004a4af0962640ed1506bb4d31329e2f8b85315fa58e39e8a10bc592
Jupyter
40,875
1,451
# %% import numpy as np from sklearn.preprocessing import OneHotEncoder # %% # keg2sym={} # sym2keg={} # f = open("./whole_Entrez.txt", "r") # for x in f: # sym=x.strip().split()[0] # kegid="hsa:"+x.strip().split()[1] # keg2sym[kegid]=sym # sym2keg[sym]=kegid # g2p={} # p2g={} # count=0 # from Bio.KEG...
84bacaba41ca57656e2e94dea2c1f0e273d76601c023294b6c49e934e85dda95
Jupyter
41,081
995
# %% import datetime import numpy as np import matplotlib.pyplot as plt from matplotlib import rcParams import tensorflow as tf from tensorflow import keras import keras.backend as K import os import sys import h5py import math import csv import pickle import glob import statistics !pip install detecta from detecta i...
63670d7197f5372a6f38ec629e50cc4348bd5a34878e8a76faf049d36c98ebd9
Jupyter
41,566
1,131
# %% # %matplotlib widget # %% import flammkuchen as fl from matplotlib import pyplot as plt import numpy as np from scipy import io import os import seaborn as sns import matplotlib.gridspec as gridspec from matplotlib.ticker import FormatStrFormatter from pathlib import Path import pandas as pd from luminance_analy...
fbd96c07bb6180a2268c779de9529a3931a11eb196608e72faf517046f72f694
Jupyter
41,808
801
# %% #import packages import vedo import numpy as np import pandas as pd import json import glob import os import networkx as nx import ast from nxviz import utils from operator import itemgetter from skimage import img_as_uint, exposure from skimage.io import imread import warnings warnings.filterwarnings('ignore') #...
b4bdee38ab488e3edd0c47a6708ee9bf026f6ccdf0ba060abf55c9ed7a348a52
Jupyter
42,057
408
# %% [markdown] # # Generate the depolymerase DB based on Interproscan entries. # *** # #### The multi fasta files of the intersting entries have already been downloaded. Here are the steps to follow : # ### I. Create a rep for each IPR entry # ### II. Cluster each entry using mmseqs # ### III. Generate the required fi...
4ef73a83542c52839f17a47b00ad76c21e756cc67fd95d92cda6a9798accb41b
Jupyter
42,064
411
# %% [markdown] # # Generate the depolymerase DB based on Interproscan entries. # *** # #### The multi fasta files of the intersting entries have already been downloaded. Here are the steps to follow : # ### I. Create a rep for each IPR entry # ### II. Cluster each entry using mmseqs # ### III. Generate the required fi...
14ebc13b4279ac976ce21ef8cf25a401741c2ab0ef67f5d36600f82a318c405c
Jupyter
42,142
1,110
# %% import warnings warnings.filterwarnings("ignore") import os import math import time import gzip import pickle import numpy as np from pathlib import Path from copy import deepcopy from time import strftime from functools import partial from skimage import io as skio from scipy.ndimage import binary_fill_holes fro...
7295645db6feb8efbec896a989af447af341f206fb2f0a079c0d11d7a70e9640
Jupyter
42,512
1,191
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import pathlib import glob import shutil import uuid import random import platform import torch import torchvision impor...
ae28b2fe5f05e594bb47aaad353b3100d75d3c8afffe54d1a437bd9952183ba2
Jupyter
42,663
1,238
# %% [markdown] # # LERCause: Causal Sentence Identification with LER (Nuclear Safety Reports) # # This code is to run pre-trained language models (BERT, BioBERT, SciBERT) on LER data for sentence classification and prediction. # # Author: # 1. Jinmo Kim: School of Information Sciences, University of Illinois Ur...
1fe05a20b86e1ba206cffedb18849ceef36f6cd68ec08ea7305d911390b58531
Jupyter
42,731
988
# %% [markdown] # <a href="https://colab.research.google.com/github/bermanlabemory/motionmapperpy/blob/master/demo/motionmapperpy_fly_demo.ipynb" target="_parent"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"/></a> # %% [markdown] # The github repositories for motionmapper are...
b9894d05bae9542ad16936de3c1e70761f38068e27aae65b22ecc3ec1efd1bd1
Jupyter
42,745
1,068
# %% #| default_exp __init__ # %% #| export import warnings from types import SimpleNamespace from typing import Union, Optional from inspect import signature from math import nan, sqrt, log, log2, pi, ceil import cmath import numpy as np from mne.utils import logger, verbose from mne.io.base import BaseRaw from mn...
79c7c4f43697cca070db4bdd1a26a344b453bba7fe8cfe7f9341641ce5d933c2
Jupyter
45,044
1,284
# %% %load_ext autoreload %autoreload 2 # %% import platform import random import uuid import os import os.path import skimage import sak import sak.signal.wavelet import sak.data import sak.data.augmentation import numpy as np import scipy as sp import scipy.signal import pandas as pd import networkx import networkx....
c332dee3a08725dcce4c6542927d92ede321dd01fe8536fb669200ad8ecb96f4
Jupyter
45,388
1,265
# %% # This Python 3 environment comes with many helpful analytics libraries installed # It is defined by the kaggle/python Docker image: https://github.com/kaggle/docker-python # For example, here's several helpful packages to load import numpy as np # linear algebra import pandas as pd # data processing, CSV file I/...
0cf38db578cf9414d1b845b8501b0aa95ffc435683dc58a97e1b8949da9349b7
Jupyter
45,594
795
# %% [markdown] # # Imports # %% proj_dir = "/path/to/main_project_folder/" # edit this line import numpy as np import random import xarray as xr import time import h5py import pandas as pd import matplotlib.pyplot as plt from tensorflow.random import set_seed as tf_set_seed import tensorflow.compat.v1 as tf_compat_v...
1d11e505b5ddb8ea74bd52ceb27fd36a77e604bc1310f6a73484bcc2993e8b61
Jupyter
46,323
1,389
# %% [markdown] # ## __XDF latency analysis of LSL data streams: Unity (triggered) vs EEG (measured)__ # # ### __Situation__ # #### Every 500ms a beep sound is played and the background color changes once one frame from black to white. # # #### __Unity (90 FPS):__ # - Color change (black or white background) # - Bee...
427b391bfcc03e48fddb4eeea051daff399a23b696dfab007388ef55214325af
Jupyter
46,639
1,099
# %% [markdown] # ### get the consensus motifs from retrained Base_model1_10000, 9000 and 8000; get the consensus motifs from Base_model2_10000, 9000 and 8000 and compare the consensus motifs from the two model structures # %% import torch import torch.optim as optim from torch.utils.data import Dataset, DataLoader, S...
44b33e290436426aedd55685f15e2c33a94c55cf6b83d05d667cc028e9d80e1b
Jupyter
46,900
979
# %% import os import math import operator from collections import defaultdict import numpy as np import pandas as pd from scipy import stats import statsmodels import statsmodels.formula.api as smf from statsmodels.multivariate.manova import MANOVA from statsmodels.tools.sm_exceptions import PerfectSeparationError fr...
e5b5d340aba53f90e80eb3210051163aee924fabc5c59df3127a1a776cfca4cf
Jupyter
47,597
1,153
# %% [markdown] # # Notebook: 2-supervised-classification # # Accompanying the paper:<br> # A. J. Lundervold, ..., A. Lundervold. _Decoding IBS: A Machine Learning Approach to Psychological Distress and Gut-Brain Interaction_ # # Arvid Lundervold, v. 2024-07-21 - using conda kernel `ibs` (Python 3.11.9)) # # Last ...
0eff6fcf767052ea41feee3bebef2b32c33c648361a03148a90754e3737b660d
Jupyter
48,125
1,085
# %% #import packages import matplotlib.pyplot as plt import os import pandas as pd import numpy as np import scipy.stats as stats import networkx as nx from operator import itemgetter from networkx.algorithms import community from nxviz import utils from tqdm import tqdm plt.rcParams['pdf.fonttype'] = 42 plt.rcParams...
c9d46fbed6db667521f7a1d203c22bdfe2cf8f1a76a2f12831abc2c8de6af2d0
Jupyter
49,096
1,107
# %% %load_ext autoreload %autoreload 2 # %% import os import os.path import skimage import skimage.segmentation import sklearn.preprocessing import sklearn.model_selection import math import shutil import pathlib import glob import shutil import uuid import random import platform import torch import torchvision impor...
306e1c575210ae78e41014d4120519ad1f8434c269f1acb776e1b3b008be264f
Jupyter
49,153
1,126
# %% [markdown] # ##### top # %% [markdown] # # This ntb analyses the Face memory perception task # # We have decided that we want to have the following measures for each participant: # # For each task (**p**erception, **b**lank, **f**aces, **em**otions) and for each difficulty level (24, 30, 36) we want to have the...
2902946810c7b8ea941c9a9980512063174c4283dd1a2d587a7bc9bf7d1aa66d
Jupyter
49,363
1,166
# %% [markdown] # # Figure 3: Inactivation # %% # Imports ## General import os from copy import deepcopy from itertools import product from types import SimpleNamespace import sys sys.path.append("..") from RNN_helpers import * from IPython.display import display, Markdown ## Numerical import numpy as np import pan...
96d25433530f4559d514165c91e55f49fca394868a26d16903493e83588f4387
Jupyter
49,548
1,207
# %% [markdown] # <a href="https://colab.research.google.com/github/michaelhess17/motionmapperpy/blob/master/demo/motionmapperpy_mouse_demo.ipynb" target="_parent"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"/></a> # %% [markdown] # The github repositories for motionmapper ar...