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
function rebin_stddev, image, new_xsize, new_ysize, image_small = image_small | |
;+ | |
; rebin_stddev | |
; It just works for making the image smaller by a integer factor (as rebin) | |
; | |
;- | |
dimensions = size(image, /dimensions) | |
number_of_pixels_combined = total(dimensions / float([new_xsize, new_ysize])) | |
; Rebin image to a smaller dimenssion | |
image_small = rebin(image, new_xsize, new_ysize) |
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 os | |
import glob | |
from astropy.io import fits | |
import sunpy.data.test | |
from sunpy.net import vso | |
from sunpy.image.rescale import resample as sunpy_image_resample | |
""" |
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 numpy as np | |
import matplotlib.pyplot as plt | |
import astropy.units as u | |
from astropy.wcs import WCS | |
from astropy.io import fits | |
from wcsaxes import WCSAxes | |
import sunpy.map | |
from sunpy.net import vso |
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
device, true_color = 24 | |
device, decomposed = 0 | |
device, retain = 2 |
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
import astropy.units as u | |
import matplotlib.pyplot as plt | |
import numpy as np | |
from skimage.measure import find_contours | |
import sunpy.map | |
xsub = 400 * u.arcsec + 75 * ([-1, 1] * u.arcsec) | |
ysub = 300 * u.arcsec + 50 * ([-1, 1] * u.arcsec) | |
map01 = sunpy.map.Map('./hmi.m_45s.2010.08.10_12_01_30_TAI.magnetogram.fits').submap(xsub, ysub) |
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
# -*- coding: utf-8 -*- | |
""" | |
Created on Sat Jun 29 21:31:58 2013 | |
@author: stuart | |
""" | |
import numpy as np | |
from datetime import timedelta |
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
#!/usr/bin/python | |
# coding=utf-8 | |
# Python version of Zach Holman's "spark" | |
# https://github.com/holman/spark | |
# by Stefan van der Walt <stefan@sun.ac.za> | |
""" | |
USAGE: |
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
;set time range: | |
timerange = ['2001-04-15','2001-04-16'] | |
cmd_url = hio_form_hfc_query(timerange=timerange,listname='VIEW_AR_HQI') | |
smart_ars = decode_votable(ssw_hio_query(cmd_url,/verb),/quiet) | |
; we should have the url on the database, but it seems it's not there (I'm taking note for that!!) | |
; but we can work around this way: | |
mdimags=mdi_time2file(timerange[0],timerange[1],/stanford) | |
lab = where(smart_ars[0].filename eq ssw_strsplit(mdimags,'/',/tail),num) | |
sock_copy,mdimags[lab],local_file=filename |
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
# SSW path | |
setenv SSW $HOME/ssw/ssw_local | |
# SSW instrument list | |
setenv SSW_INSTR "gen eit hessi secchi stereo" | |
# Set IDL paths; where you have all your wonderful creations that you will use more than once | |
setenv IDL_PATH "~/Work/IDL:+~/Superlib" | |
# set IDL startup options; Do you have any preferred options in IDL that you want them to load at the beginning? |
OlderNewer