Skip to content

Instantly share code, notes, and snippets.

View jgalazm's full-sized avatar

José Galaz Mora jgalazm

View GitHub Profile
@jgalazm
jgalazm / spec.json
Created August 23, 2023 14:24
Vega-Lite spec from Wed Aug 23 2023
{
"config": {"view": {"continuousWidth": 400, "continuousHeight": 300}},
"data": {"name": "data-ff30494553e1f5b4526afcfc733ba007"},
"mark": {"type": "line", "point": true},
"encoding": {
"color": {
"field": "mu",
"legend": {"labelLimit": 20},
"scale": {"scheme": "blues"},
"type": "ordinal"
@jgalazm
jgalazm / nwogus-spectral-radius.ipynb
Last active July 25, 2023 09:52
nwogus-spectral-radius.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
# Initialice using indices from the right-hand-side
C = np.zeros(A.shape[0], A.shape[-1], B.shape[0], B.shape[1], B.shape[3])
for p in A.shape[0]:
for s in A.shape[-1]:
for t in B.shape[0]:
for u in B.shape[1]:
for v in B.shape[3]:
# now perform the sum using indices from the LHS that did
# not show on the RHS
for q in range(A.shape[1]):
@jgalazm
jgalazm / tesseract-demo.html
Created June 14, 2019 11:55
tesseract-demo
<body>
<script src='https://unpkg.com/tesseract.js@v2.0.0-alpha.10/dist/tesseract.min.js'></script>
<script>
const { TesseractWorker } = Tesseract;
const worker = new TesseractWorker();
const imgUrl = './tes.jpg';
const img =new Image(512,512);
img.src = imgUrl;
document.body.appendChild(img);
@jgalazm
jgalazm / d3-brush-demo.html
Last active February 8, 2018 15:01
my own demo of a zoomable and resizable brush
<head>
<script src="https://d3js.org/d3.v4.min.js"></script>
</head>
<body>
<p>try 1</p>
<div id="brush"></div>
<script src="https://d3js.org/d3-color.v1.min.js"></script>
@jgalazm
jgalazm / d3-brush-demo
Created February 8, 2018 14:31
my own demo of a zoomable and resizable brush
adfasdf
@jgalazm
jgalazm / ew2py.ipynb
Created September 5, 2017 22:17
Read EasyWave binary output as python numpy arrays
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jgalazm
jgalazm / install-julia.sh
Created September 12, 2016 15:01 — forked from adriantorrie/install-julia.sh
Ubuntu 14.04 - Install The Julia Language (julia-lang)
sudo add-apt-repository ppa:staticfloat/juliareleases
sudo apt-get update
sudo apt-cache show julia
sudo apt-get install julia julia-doc -y
julia -E 'Pkg.update()'
julia
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.