Skip to content

Instantly share code, notes, and snippets.

View ehsteve's full-sized avatar
👋

Steven Christe ehsteve

👋
View GitHub Profile
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@astrofrog
astrofrog / sun_zoom_plot.py
Created March 19, 2014 22:07
Made with WCSAxes
import numpy as np
from astropy.wcs import WCS
from astropy.io import fits
from astropy import units as u
import matplotlib.pyplot as plt
from wcsaxes import WCSAxes
from sunpy.cm import get_cmap
## Definition of solar transforms (needed for now) ##
@rossant
rossant / raytracing.py
Last active August 15, 2025 21:37
Very simple ray tracing engine in (almost) pure Python. Depends on NumPy and Matplotlib. Diffuse and specular lighting, simple shadows, reflections, no refraction. Purely sequential algorithm, slow execution.
"""
MIT License
Copyright (c) 2017 Cyrille Rossant
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
@Cadair
Cadair / gist:5893586
Last active March 15, 2017 09:20
How to compensate for differential rotation in the default sunpy image. This is based upon a combination of pr/452 and pr/482 my branch for which can be found here: https://github.com/Cadair/sunpy/tree/map_refactor_diff_rot
# -*- coding: utf-8 -*-
"""
Created on Sat Jun 29 21:31:58 2013
@author: stuart
"""
import numpy as np
from datetime import timedelta