X-shooter Pipeline Reference Manual 3.8.15
Macros | Enumerations | Enumerator | Functions | Variables
Test Subtract Background

Macros

#define MODULE_ID   "XSH_COMPUTE_RESPONSE"
 
#define MODULE_ID   "XSH_SUBTRACT_BACKGROUND"
 

Enumerations

enum  { ARM_OPT , DBG_OPT }
 
enum  {
  NB_Y_OPT , RADIUS_X_OPT , RADIUS_Y_OPT , HELP_OPT ,
  MAX_FRAC_GRID_OPT , METHOD_OPT , SMOOTH_X_OPT , SMOOTH_Y_OPT ,
  MIN_FRAC_OPT
}
 

Functions

static void Help (void)
 
static void HandleOptions (int argc, char **argv)
 
int main (int argc, char **argv)
 Unit test of XSH_COMPUTE_RESPONSE.
 
static void HandleOptions (int argc, char **argv, xsh_background_param *backg_par)
 

Variables

XSH_ARM TheArm = XSH_ARM_VIS
 
char DbgLevel [8]
 
static struct option LongOptions []
 
static const char * Options = "?"
 
static const char * Options = ""
 
static struct option long_options []
 

Detailed Description

Macro Definition Documentation

◆ MODULE_ID [1/2]

#define MODULE_ID   "XSH_COMPUTE_RESPONSE"

Definition at line 57 of file test-xsh_compute_response.c.

◆ MODULE_ID [2/2]

#define MODULE_ID   "XSH_SUBTRACT_BACKGROUND"

Definition at line 55 of file test-xsh_subtract_background.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
ARM_OPT 
DBG_OPT 

Definition at line 62 of file test-xsh_compute_response.c.

◆ anonymous enum

anonymous enum
Enumerator
NB_Y_OPT 
RADIUS_X_OPT 
RADIUS_Y_OPT 
HELP_OPT 
MAX_FRAC_GRID_OPT 
METHOD_OPT 
SMOOTH_X_OPT 
SMOOTH_Y_OPT 
MIN_FRAC_OPT 

Definition at line 58 of file test-xsh_subtract_background.c.

Function Documentation

◆ HandleOptions() [1/2]

static void HandleOptions ( int  argc,
char **  argv 
)
static

Definition at line 85 of file test-xsh_compute_response.c.

References ARM_OPT, DBG_OPT, DbgLevel, Help(), LongOptions, Options, TheArm, and xsh_arm_get().

Referenced by main().

◆ HandleOptions() [2/2]

static void HandleOptions ( int  argc,
char **  argv,
xsh_background_param backg_par 
)
static

◆ Help()

static void Help ( void  )
static

Definition at line 73 of file test-xsh_compute_response.c.

References TEST_END.

Referenced by HandleOptions(), and main().

◆ main()

int main ( int  argc,
char **  argv 
)

Unit test of XSH_COMPUTE_RESPONSE.

Unit test of XSH_PREPARE.

Returns
0 if tests passed successfully

Test the Data Reduction Library function XSH_COMPUTE_RESPONSE

Returns
0 if tests passed successfully

Test the Data Reduction Library function XSH_PREPARE

Definition at line 113 of file test-xsh_compute_response.c.

References check, DbgLevel, exptime, xsh_spectrum::flux_header, HandleOptions(), Help(), instrument, MODULE_ID, TESTS_INIT, TESTS_XSH_FRAME_CREATE, TESTS_XSH_INSTRUMENT_CREATE, TheArm, XSH_ATMOS_EXT, xsh_compute_response(), XSH_DEBUG_LEVEL_LOW, XSH_DEBUG_LEVEL_NONE, xsh_debug_level_set(), xsh_free_frame(), XSH_GET_TAG_FROM_ARM, xsh_instrument_arm_tostring(), XSH_LAMP_UNDEFINED, XSH_MERGE1D, XSH_MODE_SLIT, xsh_msg, xsh_msg_dbg_medium, xsh_pfits_get_exptime(), xsh_spectrum_free(), xsh_spectrum_load(), and XSH_STD_STAR_FLUX.

Variable Documentation

◆ DbgLevel

char DbgLevel[8]

Definition at line 60 of file test-xsh_compute_response.c.

Referenced by HandleOptions(), and main().

◆ long_options

struct option long_options[]
static
Initial value:
= {
{"nb-y", required_argument, 0, NB_Y_OPT},
{"radius-x", required_argument, 0, RADIUS_X_OPT},
{"radius-y", required_argument, 0, RADIUS_Y_OPT},
{"help", 0, 0, HELP_OPT},
{0, 0, 0, 0}
}

Definition at line 65 of file test-xsh_subtract_background.c.

Referenced by HandleOptions().

◆ LongOptions

struct option LongOptions[]
static
Initial value:
= {
{"arm", required_argument, 0, ARM_OPT},
{"debug-level", required_argument, 0, DBG_OPT},
{NULL, 0, 0, 0}
}

Definition at line 66 of file test-xsh_compute_response.c.

Referenced by HandleOptions().

◆ Options [1/2]

const char* Options = "?"
static

Definition at line 71 of file test-xsh_compute_response.c.

Referenced by HandleOptions().

◆ Options [2/2]

const char* Options = ""
static

Definition at line 63 of file test-xsh_subtract_background.c.

Referenced by HandleOptions().

◆ TheArm

XSH_ARM TheArm = XSH_ARM_VIS

Definition at line 59 of file test-xsh_compute_response.c.

Referenced by HandleOptions(), and main().