Skip to content

Instantly share code, notes, and snippets.

View beckermr's full-sized avatar

Matthew R. Becker beckermr

View GitHub Profile
@beckermr
beckermr / supermongo.mplstyle
Last active January 23, 2019 17:35
supermongo
#lines
lines.linewidth : 1.0
lines.linestyle : -
lines.color : black
#fonts & text
font.family : serif
font.weight : normal
font.size : 12.0
text.color : black
@beckermr
beckermr / vi_notes.ipynb
Created September 25, 2018 15:59
VI Notes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@beckermr
beckermr / test_read.py
Last active February 22, 2019 22:59
testing code for fits strings - run test_roundtrips.py first, then test_read.py
import glob
import sys
import astropy
import astropy.table
import fitsio
IS_PY3 = tuple(sys.version_info)[0:3] >= (3, 0, 0)
def _read_fitsio(fname):
@beckermr
beckermr / test.c
Created February 25, 2019 16:15
gamma functions should be computed in log
#include <stdio.h>
#include <math.h>
#include <complex.h>
#include <gsl/gsl_sf_result.h>
#include <gsl/gsl_sf_gamma.h>
static double complex gamma_fftlog(double complex z) {
/* Lanczos coefficients for g = 7 */
static double p[] = {
@beckermr
beckermr / compile_cosmolike.md
Last active March 20, 2019 05:47
simple steps to compile cosmolike in a conda env

cosmolike install

  1. configure conda to use conda-forge

    Add the following to your ${HOME}/.condarc

    channel_priority: strict
    channels:
    
  • conda-forge
@beckermr
beckermr / gaussians.ipynb
Created June 11, 2019 11:29
make galaxies!
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@beckermr
beckermr / pytorch_lbfgs_wavelet.ipynb
Created July 10, 2019 15:52
wavelet-based image inpainting in pytorch
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
"import galsim\n",
"import numpy as np\n",

Keybase proof

I hereby claim:

  • I am beckermr on github.
  • I am beckermr (https://keybase.io/beckermr) on keybase.
  • I have a public key ASADicn9mPNaICGD0Fn8p-AOYwIrN10qUNQzUmknTyvCiAo

To claim this, I am signing this object:

@beckermr
beckermr / conda_recipe_parser.ipynb
Created February 10, 2020 15:29
conda recipe parser
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@beckermr
beckermr / check_mugration_status.py
Last active March 31, 2020 20:23
test if migration for a package is ready
import sys
import logging
from contextlib import redirect_stdout, redirect_stderr
import io
from conda_forge_tick.utils import load_graph
from conda_forge_tick.auto_tick import migration_factory
migration = sys.argv[1]