Skip to content

Commit

Permalink
Merge pull request #516 from VChristiaens/master
Browse files Browse the repository at this point in the history
Improvements to frame shifting and planet injection algorithms + Tutorial 5 update
  • Loading branch information
VChristiaens authored Apr 9, 2022
2 parents 8e9ebca + 79c0c15 commit 86c5e8a
Show file tree
Hide file tree
Showing 8 changed files with 2,287 additions and 341 deletions.
2,150 changes: 1,988 additions & 162 deletions docs/source/tutorials/05_fm_planets.ipynb

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
hciplot>0.2.0
numpy
scipy
astropy
Expand All @@ -14,5 +15,4 @@ pyprind
munch
nbsphinx
pytest
opencv-python
hciplot>0.2.0
opencv-python
14 changes: 8 additions & 6 deletions tests/test_fm_fakedisk.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ def _expected(ang):
rads = [3,4,5]
thetas = [90,180,270]

cube = cube_inject_trace(cube, psf, angles, flevel=1,
rad_dists=rads, theta=thetas,
plsc=0.01225, n_branches=1, imlib='vip-fft',
interpolation='lanczos4', verbose=True)
cube = cube_inject_trace(cube, psf, angles, flevel=1, rad_dists=rads,
theta=thetas, plsc=0.01225, n_branches=1,
imlib='vip-fft', interpolation='lanczos4',
verbose=True)

for i in range(cube.shape[0]):
# find coords of trace in each image of the cube
Expand All @@ -87,7 +87,9 @@ def _expected(ang):
coords_tmp = np.unravel_index(max_idx, frame_tmp.shape)
coords.append(coords_tmp)
frame_tmp[coords_tmp]=0

idx_order = np.argsort(np.sum(coords,axis=1))
coords_sort = [coords[i] for i in idx_order]

yx_expected = _expected(angles[i])

aarc(coords, yx_expected)
aarc(coords_sort, yx_expected)
2 changes: 1 addition & 1 deletion vip_hci/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = "1.1.3"
__version__ = "1.2.1"

from . import preproc
from . import config
Expand Down
11 changes: 9 additions & 2 deletions vip_hci/config/param.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
'latitude': -24.627,
'longitude': -70.404,
'plsc': 0.0074, # plate scale [arcsec]/px for IFS
'diam': 8.0, # telescope diameter [m]
'diam': 8.2, # telescope diameter [m]
}

VLT_SPHERE_IRDIS = {
Expand Down Expand Up @@ -56,6 +56,13 @@
'kw_type': 'HIERARCH ESO DPR TYPE' # header keyword for frame type: 'FLAT,SKY' / 'DARK' / 'OBJECT' / 'SKY'
}

GPI_IFS = {
'latitude': -30.2417,
'longitude': -70.747,
'plsc': 0.014166, # plate scale [arcsec]/px for IFS
'diam': 8.1, # telescope diameter [m]
}

LBT = {
'latitude': 32.70131, # LBT's latitude in degrees
'longitude': -109.889064, # LBT's longitude in degrees
Expand All @@ -78,7 +85,7 @@
'plsc_narrow': 0.009942, # plate scale [arcsec]/px, narrow camera
'plsc_medium': 0.019829, # plate scale [arcsec]/px, medium camera
'plsc_wide': 0.039686, # plate scale [arcsec]/px, wide camera
'diam': 8.4, # telescope diameter [m]
'diam': 10., # telescope diameter [m]
# header keywords
'camera_name': 'CAMNAME' # camera name bwt narrow, medium and wide
}
Loading

0 comments on commit 86c5e8a

Please sign in to comment.