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
div.cell.text_cell.rendered.selected | |
{ | |
border: 4px solid orange; | |
} | |
div.cell.code_cell.rendered.selected | |
{ | |
border: 4px solid orange; | |
} |
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
### JHW 2018 | |
import numpy as np | |
import umap | |
# This code from the excellent module at: | |
# https://stackoverflow.com/questions/4643647/fast-prime-factorization-module | |
import random |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
p |link_ptr|name_ptr|class_ptr|doc_ptr|data_words... | |
execute: | |
mov x1, x0+D_DATA | |
ldr x0, [x0+D_CLASS] | |
b x0 | |
bytecode: | |
mov x0, [IP] |
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 matplotlib.pyplot as plt | |
import numpy as np | |
import fractions | |
def lcm(a,b): | |
return abs(a * b) / fractions.gcd(a,b) if a and b else 0 | |
def hex_rgb_to_float(hex): | |
r = int(hex[0:2],16)/255.0 |
NewerOlder