Skip to content

Instantly share code, notes, and snippets.

View TimoRoth's full-sized avatar

Timo Rothenpieler TimoRoth

View GitHub Profile
#!/usr/bin/env python3
import tarfile
import requests
import io
class SeekableHttpStream:
def __init__(self, url, buf_size = 10 * 1024 * 1024):
self._url = url
self._buf_size = buf_size
@TimoRoth
TimoRoth / install_oggm.sh
Created May 17, 2022 22:20
OGGM venv install script
#!/bin/bash
set -xe
PIP="python3 -m pip"
export DEBIAN_FRONTEND=noninteractive
sudo apt-get -y update
sudo apt-get -y install --no-install-recommends \
gfortran \
fontconfig \
#!/bin/bash
#
#SBATCH --job-name=oggm_tests
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=4
# Abort whenever a single step fails. Without this, bash will just continue on errors.
set -e
# We create a sub-directory for this job to store its runtime data at.
#include <assert.h>
#include <stdint.h>
#include <smmintrin.h>
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <string.h>
#define CACHED_BUFFER_SIZE 8192