library(tidyverse) # devtools::install_github('tidyverse/tidyverse')
#> -- Attaching packages -------------------------------------------------------------------------------- tidyverse 1.2.1 --
#> v ggplot2 2.2.1 v purrr 0.2.4
#> v tibble 1.3.4 v dplyr 0.7.4
#> v tidyr 0.7.2 v stringr 1.2.0
#> v readr 1.1.1 v forcats 0.2.0
#> -- Conflicts ----------------------------------------------------------------------------------- tidyverse_conflicts() --
#> x dplyr::filter() masks stats::filter()
#> x dplyr::lag() masks stats::lag()
This file contains 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
#' --- | |
#' title: "Setup (with `{renv}`)" | |
#' author: "Corrado Lanera" | |
#' date: "`r date()`" | |
#' output: | |
#' html_document: | |
#' toc: true | |
#' toc_float: true | |
#' keep_md: true | |
#' --- |
This file contains 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
# import os utilities | |
import os | |
import requests, zipfile, io | |
# import numpy | |
import numpy as np | |
# images | |
import skimage | |
from skimage import transform |
This file contains 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
import types | |
def imports(): | |
for name, val in globals().items(): | |
if isinstance(val, types.ModuleType): | |
yield val.__name__ | |
print(list(imports())) |
sudo apt-get install libopenblas-base
sudo update-alternatives --config libblas.so.3-x86_64-linux-gnu # check openblas/libblas.so.3
sudo update-alternatives --config liblapack.so.3-x86_64-linux-gnu # select lapack/liblapack.so.3
This file contains 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
R package tensorflow use the conda envirnment "r-tensorflow". hence I have to install my compiled version of tf within that environment | |
1. update system and python | |
``` | |
sudo apt-get update | |
sudo apt-get upgrade | |
``` | |
2. install and update conda, and anaconda | |
``` |
This file contains 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
# download tarbal from https://www.zotero.org/download/ | |
# xvzf fro .bz, xvjf for .bz2 | |
sudo tar xvjf Zotero-5.0.70_linux-x86_64.tar.bz2 -C /opt/ | |
cd /opt/Zotero_linux-x86_64 | |
sudo ./set_launcher_icon | |
# if not already present symlink to the menu | |
ln -s /opt/zotero/zotero.desktop ~/.local/share/applications/zotero.desktop |
This file contains 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
# examples for R-4.0.2 | |
sudo wget https://cran.r-project.org/src/base/R-4/R-4.0.2.tar.gz | |
sudo tar -xvzf R-4.0.2.tar.gz | |
cd R-4.0.2 | |
# install in /opt/R to make it automatically discovered by RSSP | |
sudo ./configure --prefix=/opt/R/$(cat VERSION) --enable-memory-profiling --enable-R-shlib --with-blas --with-lapack | |
sudo make | |
sudo make install |
This file contains 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
# CL personal adjustment form https://discourse.mc-stan.org/t/rstan-rstantools-travis/6102 | |
language: R | |
sudo: true | |
cache: packages | |
env: | |
- MATRIX_EVAL="CC=gcc-7 && CXX=g++-7" | |
r_packages: |
This file contains 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
# R Benchmark 3.1 (05/2020) [Corrado Lanera] | |
# version 3.1 changed default random generator packages and functions | |
# given that the older ones are deprecated, R 4.0.0 @ Xeon 2.4GHz Ubuntu 10.04.4 LTS | |
# R Benchmark 2.5 (06/2008) [Simon Urbanek] | |
# version 2.5: scaled to get roughly 1s per test, R 2.7.0 @ 2.6GHz Mac Pro | |
# R Benchmark 2.4 (06/2008) [Simon Urbanek] | |
# version 2.4 adapted to more recent Matrix package | |
# R Benchmark 2.3 (21 April 2004) | |
# Warning: changes are not carefully checked yet! |
OlderNewer