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 numpy as np | |
from lightning.classification import SAGAClassifier | |
from scipy import sparse | |
from sklearn.datasets import load_iris, make_classification | |
from sklearn.linear_model.logistic import ( | |
LogisticRegression, | |
) | |
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
#!/usr/bin/env python | |
# | |
# Mersenne Twister predictor | |
# | |
# Feed this program the output of any 32-bit MT19937 Mersenne Twister and | |
# after seeing 624 values it will correctly predict the rest. | |
# | |
# The values may come from any point in the sequence -- the program does not | |
# need to see the first 624 values, just *any* 624 consecutive values. The | |
# seed used is also irrelevant, and it will work even if the generator was |
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 main | |
//#include<stdio.h> | |
//void inC() { | |
// printf("I am in C code now!\n"); | |
//} | |
import "C" | |
import "fmt" | |
func main() { |
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
; The stack pointer is going to be an index into the stack, and the | |
; stack is an array of words. The alternative would be to have the | |
; stack pointer me a pointer to memory, but this is perhaps a bit | |
; nicer, as where the stack actually lives is totally irrelevant. | |
@stack = global [1000 x i64] undef | |
@sp = global i64 undef; | |
; Now we have the basic stack operations: push, pop, and peek. As can | |
; be seen from the definitions, LLVM is typed, which is really nice as |
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
#!/usr/bin/env bash | |
# obtains all data tables from database | |
TS=`sqlite3 $1 "SELECT tbl_name FROM sqlite_master WHERE type='table' and tbl_name not like 'sqlite_%';"` | |
# exports each table to csv | |
for T in $TS; do | |
sqlite3 $1 <<! | |
.headers on |