Skip to content

Commit

Permalink
Fixed tests for new version of ESPRESSO masks
Browse files Browse the repository at this point in the history
  • Loading branch information
eford committed Sep 8, 2020
1 parent 076b4cf commit cca4ea8
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "RvSpectML"
uuid = "1f61ac2c-3a1c-440a-925a-2707197041c8"
authors = ["Eric B. Ford, Christian Gilbertson, Joe Ninan, Michael L. Palumbo III, Alex Wise, and contributors"]
version = "0.0.6"
version = "0.0.7"

[deps]
CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b"
Expand Down
3 changes: 3 additions & 0 deletions data/masks/citation.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ESPRESSO mask files comes from the public DRS, version 2.2.1:
https://www.eso.org/sci/software/pipelines/espresso/espresso-pipe-recipes.html --> espdr-kit-2.2.1/espdr-calib-2.2.1/cal/

2 changes: 1 addition & 1 deletion examples/neid_pipeline_1.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ using RvSpectML
target_subdir = "20190918" # USER: Replace with directory of your choice
fits_target_str = "Solar"
output_dir = "examples/output"
default_paths_to_search = [pwd(),"examples",joinpath(pkgdir(RvSpectML),"examples"),"/gpfs/group/ebf11/default/ebf11/neid/inputs"]
default_paths_to_search = [pwd(),"examples",joinpath(pkgdir(RvSpectML),"examples"), "/gpfs/group/ebf11/default/ebf11/neid_solar"]

make_plots = false
write_ccf_to_csv = true
Expand Down
14 changes: 10 additions & 4 deletions examples/param.jl
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
global linelist_for_ccf_filename = "G2.espresso.mas"
global ccf_mid_velocity = 0
global tophap_ccf_mask_scale_factor=1.6

global max_spectra_to_use = 20
global fits_target_str
global max_spectra_to_use = 200
global fits_target_str
if fits_target_str == "Solar"
global ancilary_solar_data_path = "/home/eford/Data/SolarSpectra/NEID_solar/"
global linelist_for_ccf_filename = "G2.espresso.mas"
hostname = gethostname()
if occursin("aci.ics.psu.edu",hostname)
global ancilary_solar_data_path = "/gpfs/group/ebf11/default/ebf11/neid_solar"
elseif occursin("nuc8") # Eric's home machine :)
global ancilary_solar_data_path = "/home/eford/Data/SolarSpectra/NEID_solar/"
end
global bjd_first_good = 2458745.1296134139
global bjd_last_good = 2458745.283
global df_files
Expand All @@ -15,6 +20,7 @@ if fits_target_str == "Solar"
@take(max_spectra_to_use) |>
DataFrame
elseif fits_target_str == "101501"
global linelist_for_ccf_filename = "G8.espresso.mas"
global ccf_mid_velocity = -5e3
global df_files
global df_files_use = df_files |>
Expand Down
2 changes: 1 addition & 1 deletion test/instruments/linelists.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ using Test
using DataFrames
linelist_df = read_linelist_espresso(joinpath(pkgdir(RvSpectML),"data/masks","G2.espresso.mas"))
@test typeof(linelist_df) <: DataFrame
@test size(linelist_df,1) == 5551
@test size(linelist_df,1) == 5484
@test hasproperty(linelist_df,:lambda)
@test hasproperty(linelist_df,:weight)
end
Expand Down
2 changes: 1 addition & 1 deletion test/instruments/masks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ using Test
using DataFrames
linelist_df = read_mask_espresso(joinpath(pkgdir(RvSpectML),"data/masks/G2.espresso.mas"))
@test typeof(linelist_df) <: DataFrame
@test size(linelist_df,1) == 5551
@test size(linelist_df,1) == 5484
#@test size(linelist_df,2) == 5
@test hasproperty(linelist_df,:lambda)
@test hasproperty(linelist_df,:lambda_lo)
Expand Down

0 comments on commit cca4ea8

Please sign in to comment.