Deploy to multiple snapshot repositories based on the git branch (with Travis) in a multi-module project
You have a multi-module maven project which is structured like this:
project/
pom.xml
module1/
pom.xml
other_stuff/
module2/
import numpy as np | |
def quantile_normalization(m): | |
sort_idx = np.argsort(m, axis=0) | |
ranks = np.argsort(sort_idx, axis=0) | |
sorted_cols = np.sort(m, axis=0) | |
col_ranks = sorted_cols.mean(1) | |
qnorm = col_ranks[ranks] | |
return qnorm |
import numpy as np | |
import seaborn as sns | |
from scipy.ndimage import rotate | |
def plot_heatmap_triu(m, shape=(10,10)): | |
""" | |
Plot a symmetric matrix as a triangluar heatmap. | |
- m: 2d ndarray of numpy (symmetric) |
import numpy as np | |
import networkx as nx | |
import matplotlib | |
# matplotlib.use("TkAgg") | |
import matplotlib.pyplot as plt | |
import community | |
def generate_random_connection_matrix(density=0.1, shape=10, loc=1, scale=2): |
import numpy as np | |
def pearson_correlation_matrix(m1, m2): | |
""" This function takes as input two numpy matrices m1, m2 | |
such that dim(m1) = (n,m) and dim(m2) = (r,m) and gives as a result | |
a numpy matrix such that dim(result) = (n,r) where each cell c_ij is | |
the result of the pearson correlation of the i-th row of m1 with the | |
r-th row of m2. | |
""" | |
# subtract the means |