Skip to content

Commit

Permalink
Merge pull request #195 from dstndstn/move-plots
Browse files Browse the repository at this point in the history
Move plots
  • Loading branch information
dstndstn authored Jul 15, 2020
2 parents f5d4764 + d164ba3 commit e895ab2
Show file tree
Hide file tree
Showing 46 changed files with 294 additions and 750 deletions.
11 changes: 5 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,6 @@ solver/listhead
solver/liststruc
solver/modhead
solver/new-wcs
solver/plot-constellations
solver/plotquad
solver/plotstuff
solver/plotstuff_c.py
solver/plotstuff_wrap.c
solver/plotxy
solver/solve-field
solver/query-starkd
solver/tablist
Expand All @@ -36,6 +30,11 @@ solver/wcs-grab
solver/job.axy
solver/startree
solver/fitsverify.dSYM
plot/plot-constellations
plot/plotquad
plot/plotstuff_c.py
plot/plotstuff_wrap.c
plot/plotxy
catalogs/2masstofits
catalogs/build-hd-tree
catalogs/nomadtofits
Expand Down
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,9 @@ script:
- make extra
- make test
- (cd util; ./test)
- (cd solver; ./test)
- (cd libkd; ./test)
- (cd solver; ./test)
- (cd plot; ./test)
- make install INSTALL_DIR=~/an PYTHON_SCRIPT="/usr/bin/env $PYTHON"
- ls ~/an/lib/python
- export PATH=${PATH}:~/an/bin
Expand Down
27 changes: 17 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ subdirs: gsl-an
solver: gsl-an
endif

SUBDIRS := util catalogs libkd solver sdss qfits-an
SUBDIRS := util catalogs libkd solver sdss qfits-an plot
SUBDIRS_OPT := gsl-an

subdirs: $(SUBDIRS)
Expand All @@ -83,6 +83,8 @@ catalogs: config libkd

solver: config util catalogs libkd qfits-an

plot: config util catalogs libkd qfits-an

$(SUBDIRS):
$(MAKE) -C $@
$(SUBDIRS_OPT):
Expand All @@ -98,19 +100,18 @@ html:
$(MAKE) -C doc html

# Targets that require extra libraries
extra: qfits-an util catalogs solver-cairo

solver-cairo: cairoutils
$(MAKE) -C solver cairo

.PHONY: solver-cairo
extra: qfits-an util catalogs plot-extra
.PHONY: extra

plot-extra: cairoutils
$(MAKE) -C plot cairo
.PHONY: plot-extra

# Targets that create python bindings (requiring swig)
ifneq ($(SYSTEM_GSL),yes)
py: gsl-an
endif
py: catalogs pyutil libkd-spherematch sdss cairoutils pyplotstuff
py: catalogs pyutil libkd-spherematch sdss cairoutils pyplotstuff pysolver

libkd-spherematch:
$(MAKE) -C libkd pyspherematch
Expand All @@ -119,9 +120,12 @@ cairoutils:
$(MAKE) -C util cairoutils.o

pyplotstuff: cairoutils
$(MAKE) -C solver pyplotstuff
$(MAKE) -C plot pyplotstuff

pysolver: cairoutils
$(MAKE) -C solver pysolver

.PHONY: py libkd-spherematch cairoutils pyplotstuff
.PHONY: py libkd-spherematch cairoutils pyplotstuff pysolver

pyutil: qfits-an
$(MAKE) -C util pyutil
Expand All @@ -139,6 +143,7 @@ install: all report.txt
-$(MAKE) extra
-($(MAKE) -C util install || echo "\nErrors in the previous make command are not fatal -- we try to build and install some optional code.\n\n")
-($(MAKE) -C solver install-extra || echo "\nErrors in the previous make command are not fatal -- we try to build and install some optional code.\n\n")
-($(MAKE) -C plot install-extra || echo "\nErrors in the previous make command are not fatal -- we try to build and install some optional code.\n\n")
@echo

install-core:
Expand Down Expand Up @@ -340,6 +345,7 @@ test:
$(MAKE) -C catalogs test
$(MAKE) -C libkd test
$(MAKE) -C solver test
$(MAKE) -C plot test
.PHONY: test

clean:
Expand All @@ -352,6 +358,7 @@ clean:
$(MAKE) -C libkd clean
$(MAKE) -C solver clean
$(MAKE) -C sdss clean
$(MAKE) -C plot clean

realclean: clean

Expand Down
2 changes: 1 addition & 1 deletion __init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.80-52-g703879af'
__version__ = '0.80-60-g5effbe00'
2 changes: 1 addition & 1 deletion net/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ def get_anns(cal, nbright=0):
hipfn = settings.HIPPARCOS_CAT
tycho2fn = settings.TYCHO2_KD

import astrometry.solver.plotann as plotann
import astrometry.plot.plotann as plotann
opt = plotann.get_empty_opts()
if nbright:
opt.nbright = nbright
Expand Down
2 changes: 1 addition & 1 deletion net/galex_jpegs.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from astrometry.util.fits import fits_table
from astrometry.util.util import Tan
from astrometry.solver import plotstuff as ps
from astrometry.plot import plotstuff as ps
from astrometry.util.starutil_numpy import *

from astrometry.net.log import *
Expand Down
2 changes: 1 addition & 1 deletion net/sdss_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

def plot_sdss_image(wcsfn, plotfn, image_scale=1.0, debug_ps=None):
from astrometry.util import util as anutil
from astrometry.solver import plotstuff as ps
from astrometry.plot import plotstuff as ps
# Parse the wcs.fits file
wcs = anutil.Tan(wcsfn, 0)
# grab SDSS tiles with about the same resolution as this image.
Expand Down
4 changes: 2 additions & 2 deletions net/views/image.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
from astrometry.net.tmpfile import *
from astrometry.net.sdss_image import plot_sdss_image

from astrometry.solver.plotstuff import *
from astrometry.plot.plotstuff import *
from astrometry.util import image2pnm
from astrometry.util.run_command import run_command
from astrometry.util.file import *
Expand Down Expand Up @@ -389,7 +389,7 @@ def onthesky_image(req, zoom=None, calid=None):

def galex_image(req, calid=None, size='full'):
from astrometry.util import util as anutil
from astrometry.solver import plotstuff as ps
from astrometry.plot import plotstuff as ps
from astrometry.net.galex_jpegs import plot_into_wcs
cal = get_object_or_404(Calibration, pk=calid)
key = 'galex_size%s_cal%i' % (size, cal.id)
Expand Down
2 changes: 1 addition & 1 deletion net/views/onthesky.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from astrometry.net import settings

from astrometry.util import util as anutil
from astrometry.solver import plotstuff as ps
from astrometry.plot import plotstuff as ps

def plot_wcs_outline(tanwcs, plotfn, W=256, H=256, width=36, zoom=True,
zoomwidth=3.6, grid=10, hd=False, hd_labels=False,
Expand Down
Loading

0 comments on commit e895ab2

Please sign in to comment.