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
''' | |
Based on the Python implementation by Alessandro Bessi at https://github.com/alessandrobessi/corcondia | |
and the original MATLAB implementation by Evangelos (Vagelis) Papalexakis at https://www.cs.ucr.edu/~epapalex/src/efficient_corcondia.zip | |
Updated to work with modern versions of Python. | |
Uses Tensorly, and assumes that we use the numpy backend. | |
References: | |
Buis, Paul E., and Wayne R. Dyksen. | |
"Efficient vector and parallel manipulation of tensor products." |
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
name: copy 1s | |
source code: | | |
# input: 'aaaaaaaaaaaaaaaaaaaaaaaaab11001' | |
input: 'aaaaaab10' | |
blank: ' ' | |
start state: q_0 | |
table: | |
q_0: | |
a: {R: s_b, write: x} | |
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
--filter=-whitespace/parens,-legal/copyright,-build/namespaces,-build/header_guard,-build/include_subdir,-runtime/references,-build/include |
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
package main | |
import ( | |
"crypto/aes" | |
"crypto/cipher" | |
"crypto/rand" | |
"crypto/sha256" | |
"encoding/base64" | |
"fmt" | |
"io" |
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
syntax on | |
set nocompatible " break away from old vi compatibility | |
set number " Line numbers | |
set backspace=2 " Normal backspaces! | |
set ruler " show current position at bottom | |
filetype on " Enable filetype detection | |
filetype indent on " Enable filetype-specific indenting | |
filetype plugin on " Enable filetype-specific plugins | |
set smarttab " tab and backspace are smart | |
set autoindent " set the cursor at same indent as line above |