-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update output image and add PDF output
- Loading branch information
Showing
6 changed files
with
92 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# ============================================================================= | ||
# @file Makefile | ||
# @brief Makefile for generating previews of the paper | ||
# @author Michael Hucka <mhucka@caltech.edu> | ||
# @license Please see the file named LICENSE in the project directory | ||
# @website https://github.com/casics/dassie | ||
# ============================================================================= | ||
|
||
# Change the following values to match your configuration. | ||
# ............................................................................. | ||
|
||
input := paper.md | ||
output := paper.pdf | ||
bib := paper.bib | ||
|
||
# Main code -- no more customization variables after this point | ||
# ............................................................................. | ||
|
||
title := $(shell grep title: $(input) | sed 's/title: *//' | tr -d "'") | ||
authors := $(shell sed -n '/authors:/,/affiliations:/p' $(input) | grep name: | sed 's/- name: *//' | paste -d, -s - | sed 's/,/, /g') | ||
repo := $(shell git config --get remote.origin.url | sed 's|git@github.com:|https://github.com/|' | sed 's/\.git//') | ||
#repo := https://github.com/hipspy/hips | ||
|
||
$(output): $(input) $(bib) Makefile | ||
pandoc \ | ||
-V paper_title="$(title)" \ | ||
-V citation_author="$(authors)" \ | ||
-V repository="$(repo)" \ | ||
-V archive_doi="http://dx.doi.org/00.00000/zenodo.0000000" \ | ||
-V formatted_doi="00.00000/joss.00000" \ | ||
-V paper_url="http://joss.theoj.org/papers/" \ | ||
-V review_issue_url="http://joss.theoj.org/papers/" \ | ||
-V issue="0" \ | ||
-V volume="00" \ | ||
-V year="2018" \ | ||
-V submitted="00 January 0000" \ | ||
-V published="00 January 0000" \ | ||
-V page="00" \ | ||
-V graphics="true" \ | ||
-V joss_logo_path="whedon/resources/joss-logo.png" \ | ||
-V logo_path="whedon/resources/joss-logo.png" \ | ||
-V footnote_paper_title="..." \ | ||
-V geometry:margin=1in \ | ||
-V journal_name="JOSS" \ | ||
-o $(output) \ | ||
--pdf-engine=xelatex \ | ||
--filter pandoc-citeproc $(input) \ | ||
--from markdown+autolink_bare_uris \ | ||
--template "whedon/resources/latex.template" | ||
|
||
autorefresh:; | ||
((ls $(input) $(bib) | entr make $(output)) &) |
Binary file not shown.
Loading
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
"""Basic example how to plot a sky image with the hips package""" | ||
from astropy.coordinates import SkyCoord | ||
from hips import WCSGeometry, HipsPainter | ||
|
||
# Compute the sky image | ||
geometry = WCSGeometry.create( | ||
skydir=SkyCoord(0, 0, unit='deg', frame='galactic'), | ||
width=2000, height=1000, fov="3 deg", | ||
coordsys='galactic', projection='AIT', | ||
) | ||
hips_survey = 'IPAC/P/GLIMPSE360' | ||
|
||
fetch_opts = dict(fetch_package='urllib', timeout=30, n_parallel=10) | ||
painter = HipsPainter(geometry, hips_survey, 'jpg', fetch_opts=fetch_opts) | ||
painter.run() | ||
painter.plot_mpl_hips_tile_number_grid() |
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