parameter for algorithm switch from baseline to fallback

Data formats, HDF5, XML profiles, etc.
Post Reply
lucy liu
Posts: 54
Joined: Tue Oct 18, 2011 11:02 am

parameter for algorithm switch from baseline to fallback

Post by lucy liu »

I would like to switch the algorithm from baseline to fallback.
I noticed that in the ProEdrViirsLstControllerLwFile.xml , there is one called executionMode, which has primary and backup options.
I wonder if this is the parameter I should change in order for the switch.

From the ProEdrViirsLstController_CFG.xml, I can not tell what the algorithm1(ProAncViirsController) and 2(ProEdrViirsLst) stand for.
Thanks.
bhenders
Posts: 72
Joined: Wed Jan 05, 2011 9:27 am
Location: Omaha, NE

Re: parameter for algorithm switch from baseline to fallback

Post by bhenders »

I'm not exactly sure what you are wanting when you say that you would like to switch the algorithm from baseline to fallback, but I'm almost certain that the executionMode in the run-time configuration file is not what you want. This executionMode is only applicable to IDPS and affects nothing in ADL.

What I believe you are asking is how to toggle the LST algorithm mode between split and dual mode. If that is what you are wanting to do it will require manipulating the configurable coefficient binary file that is an input to the LST algorithm for the algmode field. That input in the dropped ADL data is:

4dc4242d-1f6f2-9b9dea23-e963b8e2.VIIRS-LST-EDR-AC_npp_20020101010000Z_20020101010000Z_ee00000000000000Z_1_devl_dev_noaa_ops.xml_Internal

The following structure can be used as an overlay for that binary, where the algmode is the last 4 bytes of the above binary file.

struct IngMsdCoefficients_ViirsLstStruct
{
Float32 min_Bt_M12_M13;

Float32 max_Bt_M12_M13;

Float32 min_Bt_M15;

Float32 max_Bt_M15;

Float32 min_Bt_M16;

Float32 max_Bt_M16;

Float32 day_Sol_Zen_Ang_Lim;

Float32 min_Hcs_Sens_Zen_Lim;

Float32 max_Hcs_Sens_Zen_Lim;

Float32 min_Term_Lim;

Float32 max_Term_Lim;

Float32 lst_Min_Rept_Range;

Float32 lst_Max_Rept_Range;

Float32 max_Sens_Zen_Lim;

Int32 algmode;

};

If this is not what you were asking, please post back with more details.

Thanks,

Bryan Henderson
Raytheon Company
lucy liu
Posts: 54
Joined: Tue Oct 18, 2011 11:02 am

Re: parameter for algorithm switch from baseline to fallback

Post by lucy liu »

You are right, I want to switch from dual to split algorithm.
I found the value for algmode is 16777216. I suppose the value of 16777216 is for dual window.
Could you tell me the value for split window? How to set this value?

Thanks very much
bhenders
Posts: 72
Joined: Wed Jan 05, 2011 9:27 am
Location: Omaha, NE

Re: parameter for algorithm switch from baseline to fallback

Post by bhenders »

The algmode flag should just have valus of "0" or "1". When I do "od" on the binary file for the configurable coefficients that was dropped, this is the contents the last 4 bytes have:

bhenders-> od -Ax -tx 4dc4242d-1f6f2-9b9dea23-e963b8e2.VIIRS-LST-EDR-AC_npp_20020101010000Z_20020101010000Z_ee00000000000000Z_1_devl_dev_noaa_ops.xm>
0000000 43340000 43af0000 43340000 43af0000
0000010 43340000 43af0000 3fbde44e 00000000
0000020 3f6cce68 3fbde44e 3fdf66f3 43550000
0000030 43ab8000 3f32b8c2 00000001
000003c

Note the 00000001 is the integer value of a "1" which indicates that split mode is turned on. If you want to run with dual mode you will need to manipulate the last 4 bytes of the binary file to have a "0" value instead of a "1".

// LST algorithm mode constants
const Int32 LST_DUAL_MODE_ALG = 0;
const Int32 LST_SPLIT_MODE_ALG = 1;

But your large number value is not correct.

Bryan Henderson
Raytheon Company
lucy liu
Posts: 54
Joined: Tue Oct 18, 2011 11:02 am

Re: parameter for algorithm switch from baseline to fallback

Post by lucy liu »

This is what I got when I do "od" on the original binary file.
000000 00003443 0000af43 00003443 0000af43
000010 00003443 0000af43 4ee4bd3f 00000000
000020 68ce6c3f 4ee4bd3f f366df3f 00005543
000030 0080ab43 c2b8323f 01000000
00003c

As you said, the algmode is 01000000. Looks like we have different endian type. I used the tool to convert the endian and do "od" again and get the same result as yours.
And now the value shows 1.

My question is that if I want to use the original file with big endian, what should I put for algmode equal to "1", just 1 or still 16777216?

I followed the manual to edit this filed and that is what the tool shows to me. This file comes with ADL3.1 package and has never been edited yet.

Thanks.
bhenders
Posts: 72
Joined: Wed Jan 05, 2011 9:27 am
Location: Omaha, NE

Re: parameter for algorithm switch from baseline to fallback

Post by bhenders »

Ok, I completely forgot about the Little Endian versus Big endian aspect. You'll have to forgive me, I'm so Big Endian focused with IDPS. So the decimal 16777216 when converted to a hexadecimal value is 0x01000000, which is just the bytes reversed, which is what you'd get out when dumping the BE binary that was dropped on a LE platform. Like you said you can convert it to LE for editing in the Binary Editor, then it should display as an 0x00000001 value. However, after saving it you would then need to convert it back to Big Endian format, as the algorithm as dropped defaults to always wanting a big endian input. Bottom line is 16777216 needs to become a 0 or a "1" needs to become a 0. Luckily a 0 byte swapped on any platform for an integer is still just a 0.

I see you posted an issue with the binary editor also. I'll try to bring it up on a LE platform and see if I can replicate the issues you were having.
Post Reply