# HG changeset patch # User thomaswollmann # Date 1486632997 18000 # Node ID 8fcbcf6509d8db4f6c04b9c3b376b0a882579b85 # Parent e5d95eb1daad21904f78812044da84cdce85abcc planemo upload for repository https://github.com/BMCV/galaxy-image-analysis/tools/color-deconvolution commit 92068c64f9a6c3cf59f756b9efc2d561196c6873 diff -r e5d95eb1daad -r 8fcbcf6509d8 color-deconvolution.xml --- a/color-deconvolution.xml Tue Feb 07 10:29:32 2017 -0500 +++ b/color-deconvolution.xml Thu Feb 09 04:36:37 2017 -0500 @@ -1,4 +1,4 @@ - + Color deconvolution scikit-image @@ -14,7 +14,10 @@ - + + + + diff -r e5d95eb1daad -r 8fcbcf6509d8 color_deconvolution.py --- a/color_deconvolution.py Tue Feb 07 10:29:32 2017 -0500 +++ b/color_deconvolution.py Thu Feb 09 04:36:37 2017 -0500 @@ -5,7 +5,7 @@ import skimage.io import skimage.color import skimage.util -from sklearn.decomposition import PCA +from sklearn.decomposition import PCA, NMF, FastICA, FactorAnalysis convOptions = { 'hed2rgb' : lambda img_raw: skimage.color.hed2rgb(img_raw), @@ -61,6 +61,12 @@ 'hpx_from_rgb' : lambda img_raw: skimage.color.separate_stains(img_raw, skimage.color.hpx_from_rgb), 'pca' : lambda img_raw: np.reshape(PCA(n_components=3).fit_transform(np.reshape(img_raw, [-1, img_raw.shape[2]])), + [img_raw.shape[0],img_raw.shape[1],-1]), + 'nmf' : lambda img_raw: np.reshape(NMF(n_components=3, init='nndsvda').fit_transform(np.reshape(img_raw, [-1, img_raw.shape[2]])), + [img_raw.shape[0],img_raw.shape[1],-1]), + 'ica' : lambda img_raw: np.reshape(FastICA(n_components=3).fit_transform(np.reshape(img_raw, [-1, img_raw.shape[2]])), + [img_raw.shape[0],img_raw.shape[1],-1]), + 'fa' : lambda img_raw: np.reshape(FactorAnalysis(n_components=3).fit_transform(np.reshape(img_raw, [-1, img_raw.shape[2]])), [img_raw.shape[0],img_raw.shape[1],-1]) }