Skip to content

vlas-sokolov/gethigal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gethigal

A selenium webscraper for automated download of the Hi-GAL DR1 data products.

Dependencies

  • Python 3.x
  • Firefox with geckodriver
  • selenium
  • astropy

Drawbacks

  • Some manual interaction with Firefox is still required
  • Default download directory has to hacked around

Installation

To clone and install gethigal locally:

git clone https://github.com/vlas-sokolov/gethigal.git
cd gethigal
pip install .

Example use

The following code snippet downloads the Hi-GAL maps in a 15 arcminute radius around the IRDC G035.39-00.33:

import os
import astropy.units as u
import astropy.coordinates as c
from gethigal.requestform import RequestForm

home_dir = os.path.expanduser('~')

radius = 15*u.arcmin
skycoord_g035_39 = c.SkyCoord(284.2875*u.deg, 2.1294*u.deg, frame = 'fk5')

# Opens a Firefox session with "save file" pop-ups
getter = RequestForm(skycoord_g035_39, radius, submit = True)

# After the files are saved, moves them to a designated directory
getter.fix_download_loc(os.path.join(home_dir, 'Downloads/'), 'data/',
                        globber = "HIGAL*354*.fits", lay_low = True)

# Quits the browser session
getter.quit()

About

A selenium webscraper for automated download of the Hi-GAL data products.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages