This file contains hidden or 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 networkx | |
import sys | |
G = networkx.Graph() | |
argvs = sys.argv | |
if( len(argvs) != 4 ): | |
print 'Usage: python %s <d> <n> <seed>' % argvs[0] | |
quit() | |
d = int( argvs[1] ) | |
n = int( argvs[2] ) |
This file contains hidden or 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
require './config/environment' | |
psq_id = ARGV[0] | |
psq = ParameterSetQuery.find(psq_id) | |
$stderr.puts "Number of found PS: #{psq.parameter_sets.count}" | |
def replace_runs(run) | |
run_attr = { submitted_to: run.submitted_to, | |
mpi_procs: run.mpi_procs, | |
omp_threads: run.omp_threads, |
This file contains hidden or 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
sudo yum update | |
echo "[MongoDB] | |
name=MongoDB Repository | |
baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64 | |
gpgcheck=0 | |
enabled=1" | sudo tee -a /etc/yum.repos.d/mongodb.repo | |
sudo yum install -y mongodb-org-server mongodb-org-shell mongodb-org-tools | |
sudo service mongod start | |
sudo chkconfig mongod on |
This file contains hidden or 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
var fileref=document.createElement('script') | |
fileref.setAttribute("type","text/javascript") | |
fileref.setAttribute("src", "http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML") | |
document.getElementsByTagName("head")[0].appendChild(fileref) |
This file contains hidden or 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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <pthread.h> | |
#include <omp.h> | |
#define NTHREADS 4 | |
void *myFun(void *x) | |
{ | |
int tid; |
This file contains hidden or 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
#include <iostream> | |
#define _USE_MATH_DEFINES | |
#include <cmath> | |
#include <boost/math/special_functions/beta.hpp> | |
double Q_k0( double f0, double k0, double k ) { | |
double c = 1.0 / ( f0 * (k0+1.0) ); | |
double x = f0 / (1.0-f0); | |
double a = k + 1.0; |
This file contains hidden or 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 x10.io.Console; | |
import x10.util.Timer; | |
class ParallelHelloWorld { | |
public static def main(args:Rail[String]):void { | |
val timer = new Timer(); | |
val begin = timer.milliTime(); | |
finish for (p in Place.places()) { | |
async at (p) { | |
Console.OUT.println("Hello, I'm " + here); |
This file contains hidden or 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
from tensorflow.examples.tutorials.mnist import input_data | |
mnist = input_data.read_data_sets("MNIST_data/", one_hot=True) | |
import tensorflow as tf | |
x = tf.placeholder(tf.float32, [None, 784]) | |
W = tf.Variable(tf.zeros([784, 10])) | |
b = tf.Variable(tf.zeros([10])) | |
y = tf.nn.softmax(tf.matmul(x, W) + b) | |
y_ = tf.placeholder(tf.float32, [None, 10]) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.