X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 16 May 2007 11:34 PM by  anon
Question on MODIS albedo processing with IDL-'Spawn' statement
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
16 May 2007 11:34 PM
    Hi, everyone! I am back to ask a question on albedo processing with IDL. I am dealing with MODIS43 for processing albedo. As most of you may know, however, MODIS43 only provides black sky albedo (BSA) and white sky albedo (WSA). We need to calculate actual albedo based on these values. Recently I downloaded the look up table (sky_lut.dat) and several source codes from ... http://www-modis.bu.edu/b...userguide/tools.html However, these files are written in C. Because I am not familiar with C yet, I got stuck now. At this point, I have two questions¡¦ 1. Is there anyone who has been working on MODIS43-albedo processing with IDL (not with C)? If there is someone, please let me know. 2. I found the ¡®spawn¡¯ statement dealing with the codes written in other computer languages (i.e: FORTRAN or C) in IDL environment. But I don¡¯t know how to begin. If I want to run ¡®tell_skyl.c¡¯ code with ¡®spawn¡¯ statement, what can I do? Harry -------------------------------- Tell_skyl.c /** * Calculate fraction of diffuse skylight through a look-up table * which was pre-calculated with the 6S code for seven MODIS land spectral * bands plus three broadbands (visible, NIR and shortwave) * [-od] aerosol optical depth at 550nm [0..1] * [-szn] solar zenith angle [0..89] * * by Feng Gao at Boston University on July 2002 * contact fgao@bu.edu * **/ #include #include typedef struct { int aerosol_type; int bandno; float solar_zenith; float optical_depth; float skyl; } SKYL; void read_skyl_table (float skyl_lut[2][10][90][50]); float get_skyl (SKYL s,float skyl_lut[2][10][90][50]); void main(int argc, char **argv) { int i,band; float skyl_lut[2][10][90][50]; SKYL s; if(argc!=5) { printf("Usage example: %s -od 0.2 -szn 30.0\n", argv[0]); exit(1); } /* parse command line */ for(i=1;i=50) od=49; return skyl_lut[s.aerosol_type][s.bandno][szn][od]; }

    Deleted User



    New Member


    Posts:
    New Member


    --
    16 May 2007 11:34 PM
    See the message threads anchored at #3295 for the answer to this question. James Jones
    You are not authorized to post a reply.