Page 1 of 1

how to merge more fire granule to one file and add all field to .txt file

Posted: Wed Jun 21, 2023 10:56 pm
by PrasitGistda
Hi all,

I use cspp_active_fire_noaa.sh to process fire products but the output is more granule. How can I merge more fire granules to one file and for .txt a field in .txt is not equal .nc file how can I add all fields to .txt

Best regard.
Thank you very much.

Re: how to merge more fire granule to one file and add all field to .txt file

Posted: Thu Jun 22, 2023 10:05 am
by kathys
To remove the header information and concatenate the granule based CSPP Active Fire output .txt files (example: AFIMG_j01_d20230621_t1838523_e1840150_b28963_c20230621192728707386_cspp_dev.txt), you can use the command:

For I-Band resolution files:

cat AFIMG*cspp_dev.txt | grep -v '#' | sed 's/ //g' > AFIMG_all.txt

For M-Band resolution files:

cat AFMOD*.txt | grep -v '#' | sed 's/ //g' > AFMOD_all.txt

Where AFIMG_all.txt and AFMOD_all.txt are the output concatenated text files.

Good luck,

Kathy

Re: how to merge more fire granule to one file and add all field to .txt file

Posted: Fri Jun 23, 2023 1:15 am
by PrasitGistda
Now we can solve .txt and another problem How can I merge more .nc fire granules into one file?

Thank you