Skip to content

Instantly share code, notes, and snippets.

@msarahan
msarahan / Conda-build rendering tour.ipynb
Last active Feb 14, 2020
Conda-build rendering overview
View Conda-build rendering tour.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View sd_data.diff
diff --git a/conda/core/subdir_data.py b/conda/core/subdir_data.py
index ec4a60958..cde9b5b75 100644
--- a/conda/core/subdir_data.py
+++ b/conda/core/subdir_data.py
@@ -7,6 +7,7 @@ import bz2
from collections import defaultdict
from contextlib import closing
from errno import EACCES, ENODEV, EPERM, EROFS
+from functools import partial
from genericpath import getmtime, isfile
@msarahan
msarahan / example output
Created Jul 8, 2019
conda 4.7.5 install/update/remove with free channel
View example output
CONDA_RESTORE_FREE_CHANNEL: command not found
(base) msarahan@ubuntu:~$ CONDA_RESTORE_FREE_CHANNEL=1 conda create -n old_python python=3.5.1
Collecting package metadata (current_repodata.json): done
Solving environment: done
## Package Plan ##
environment location: /home/msarahan/miniconda3/envs/old_python
added / updated specs:
@msarahan
msarahan / gdal-activate.bat
Last active Feb 25, 2019
post-link scripts for Fonnesbeck env
View gdal-activate.bat
@REM Store existing GDAL env vars and set to this conda env
@REM so other GDAL installs don't pollute the environment
@if defined GDAL_DATA (
set "_CONDA_SET_GDAL_DATA=%GDAL_DATA%"
)
@set "GDAL_DATA=%CONDA_PREFIX%\Library\share\gdal"
@if defined GDAL_DRIVER_PATH (
set "_CONDA_SET_GDAL_DRIVER_PATH=%GDAL_DRIVER_PATH%"
@msarahan
msarahan / migrate.py
Created Jan 30, 2019
Migrate an MRO-based conda environment to an Anaconda-R-based environment
View migrate.py
from argparse import ArgumentParser
import os
import subprocess
import tempfile
from fnmatch import fnmatch
from six import string_types
import yaml
@msarahan
msarahan / mistakes.md
Last active Aug 22, 2018
Metadata mistakes & how to address them
View mistakes.md

pin_compatible on numpy's numpy-base dependency

Comes from:

# metapackage for things that don't use numpy's C interface, or things
- name: numpy
  requirements:
    build:
      # for runtime alignment
      - {{ compiler('c') }}
View 0001-incorporate-https-github.com-tensorflow-tensorflow-p.patch
From 9147d00f50fafd45d6df6c4dbb7ec0dcd6b3dfe0 Mon Sep 17 00:00:00 2001
From: Michael Sarahan <msarahan@gmail.com>
Date: Fri, 29 Jun 2018 12:30:19 +0100
Subject: [PATCH] incorporate
https://github.com/tensorflow/tensorflow/pull/20284 up to c858523
---
tensorflow/tools/pip_package/BUILD | 8 +-
tensorflow/tools/pip_package/build_pip_package.sh | 2 +-
tensorflow/workspace.bzl | 14 ++
@msarahan
msarahan / ext.pyx
Last active Jul 25, 2019
validation of MKL 2018.0.3 openmp initialization fixes
View ext.pyx
cimport numpy as np
import numpy as np
import cython
from cython.parallel import prange
@cython.boundscheck(False)
@cython.wraparound(False)
@cython.cdivision(True)
def p_arange(int n):
'''
@msarahan
msarahan / gerrymandr_env.txt
Last active Jun 3, 2018
Conda env spec for gerrymandr school 2018
View gerrymandr_env.txt
python >=3.6
descartes
geopandas
cartopy
fiona
gdal
geos
matplotlib
numpy
pandas
@msarahan
msarahan / build order - linux
Created Apr 23, 2018
AnacondaRecipesSync build order - linux
View build order - linux
bzip2-feedstock
ncurses-feedstock
perl-feedstock
libedit-feedstock
sqlite-feedstock
zlib-feedstock
readline-feedstock
openssl-feedstock
tk-feedstock
libffi-feedstock