Description | Command |
---|---|
Start a new session with session name | screen -S <session_name> |
List running sessions / screens | screen -ls |
Attach to a running session | screen -x |
Attach to a running session with name | screen -r |
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
## | |
## Linear regression by gradient descent | |
## | |
## A learning exercise to help build intuition about gradient descent. | |
## J. Christopher Bare, 2012 | |
## | |
# generate random data in which y is a noisy function of x | |
x <- runif(1000, -5, 5) | |
y <- x + rnorm(1000) + 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
package net.ladstatt.apps.watersimulation | |
import scala.collection.JavaConversions.seqAsJavaList | |
import javafx.animation.Animation | |
import javafx.animation.KeyFrame | |
import javafx.animation.Timeline | |
import javafx.application.Application | |
import javafx.event.ActionEvent | |
import javafx.event.EventHandler |
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
UNAME_S := $(shell uname -s) | |
# -std=c++11 -Wall -march=native | |
ifeq ($(UNAME_S),Linux) | |
CXX=clang++ | |
CPPFLAGS=-O3 | |
LDFLAGS=-O3 | |
LDLIBS=-lOpenCL | |
endif | |
ifeq ($(UNAME_S),Darwin) |
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
-- These queries let you define find user sessions against event data | |
-- logged to Segment SQL, Snowplow, or Google BigQuery. | |
-- For more details, see the full post: | |
-- LINK | |
--- SEGMENT SQL | |
-- Finding the start of every session | |
SELECT * | |
FROM ( |
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
''' | |
This script performs efficient concatenation of files stored in S3. Given a | |
folder, output location, and optional suffix, all files with the given suffix | |
will be concatenated into one file stored in the output location. | |
Concatenation is performed within S3 when possible, falling back to local | |
operations when necessary. | |
Run `python combineS3Files.py -h` for more info. | |
''' |
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
## install Catalyst proprietary | |
sudo ntfsfix /dev/sda2 | |
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.BAK | |
sudo apt-get remove --purge fglrx* | |
sudo apt-get install linux-headers-generic | |
sudo apt-get install fglrx xvba-va-driver libva-glx1 libva-egl1 vainfo | |
sudo amdconfig --initial | |
## install build essentials | |
sudo apt-get install cmake |
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 java.io.InputStream | |
import org.apache.spark.sql.execution.datasources.jdbc.JdbcUtils | |
import org.apache.spark.sql.{ DataFrame, Row } | |
import org.postgresql.copy.CopyManager | |
import org.postgresql.core.BaseConnection | |
val jdbcUrl = s"jdbc:postgresql://..." // db credentials elided | |
val connectionProperties = { |
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
service pve-cluster restart && service pvedaemon restart && service pvestatd restart && service pveproxy restart |
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
<pyopencl.Device 'Tonga' on 'AMD Accelerated Parallel Processing' at 0x749460> | |
Repeating [test_overwrite_ecb()] 1000 times.... | |
Function [test_overwrite_ecb] finished in average of 0:00:00.003962 | |
Repeating [test_overwrite_efb()] 1000 times.... | |
Function [test_overwrite_efb] finished in average of 0:00:00.002380 | |
OlderNewer