Coder Social home page Coder Social logo

saverx's Introduction

SAVERX

R package for transfer learning of scRNA-seq denoising. Take a look at our free SAVER-X web-server for the transfer learning online computation! We also encourage you to read our pre-print manucript for more information. You can also refer to our earlier denoising method SAVER.

Updates

11/12/2019: fix the bug in SAVER-X by requiring the reticulate package to be updated to version 1.13

8/14/2019: SAVER-X now accepts either a data file or a matrix object in R as input, and creates a new folder under current working directory to store intemediate and final results. It returns the file name storing the denoised results.

Installation

First, install the supporting Python package sctransfer. See the source code of the package here

pip install sctransfer

Next, open R and install the R package SAVERX

library(devtools)
install_github("jingshuw/SAVERX")

Basic Usage

Our current pre-trained models can be downloaded here

Our input can be either a data file or a dense/sparse matrix. The data file can be '.txt', '.csv' or '.rds' file. The '.rds' file can store either a matrix or a sparse matrix of class 'dgCMatrix'. As a toy example, you may download one of our demo datasets on the web server, shekhar_downsampled.csv, the down-sampled mouse retina data from here. SAVER-X will generate a new folder based on the current time to store intemediate files and final results and return the file name storing the denoised matrix.

SAVER-X without pretraining

library(SAVERX)
file <- saverx("./testdata/shekhar_downsampled.csv")
denoised.data <- readRDS(file)

SAVER-X with a pretrained model

For the demo dataset, we have a pre-trained model for the mouse retina, please download the file, mouse_Retina.hdf5, and you may save it in './mouse_retina.hdf5'

library(SAVERX)
file <- saverx("./testdata/shekhar_downsampled.csv", data.species = "Mouse", 
use.pretrain = T, pretrained.weights.file = "./mouse_retina.hdf5", model.species = "Mouse")
denoised.data <- readRDS(file)

For both cases, object 'denoised.data' is your final denoised matrix. When dealing with large datasets, you can set 'is.large.data = T' to reduce RAM. Set 'clearup.python.session = F' if you plan to run SAVER-X more than once in your R session.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.