# Could not generate individual file names for file set "PGTS3D\_L"

**URL:** <https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105>\
**Category:** Run Errors and Warnings\
**Created:** [March 17, 2022, 2:45am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105 "2022-03-17T02:45:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gwangjin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/gwangjin/32/1336_2.png) [@gwangjin](https://forum.cmascenter.org/u/gwangjin)\
**Post date:** [March 17, 2022, 2:45am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/1 "2022-03-17T02:45:58Z")

</div>

Hello,

I’m merging point (3D), area, and non-road sources using `MRGGID` in SMOKE v4.8.1.

> setenv MRGFILES “AGTS\_L NGTS\_L PGTS3D\_L” # logical file names to merge

and I met an error message:

> —\>\> WARNING in subroutine OPENSET  
> Could not generate individual file names for file set “PGTS3D\_L”  
> Could not open file “PGTS3D\_L”.  
> \*\*\* ERROR ABORT in subroutine MRGGRID  
> Ending program “MRGGRID”.

But, when I went to the output directory, I found there was the PGTS3D\_L file.

> ls  
> agts\_l.area.20181103.4.Cheongju30\_5km.capss2018.ncf  
> agts\_l.nonroad.20181103.4.Cheongju30\_5km.capss2018.ncf  
> pgts3d\_l.point.20181103.4.Cheongju30\_5km.capss2018.ncf

I don’t know why MRGGRID could not generate individual file names for file set “PGTS3D\_L”. I attached the related files.

[smk\_mrgall\_capss2018.csh](https://forum.cmascenter.org/uploads/short-url/ufKpzDZHSvXNwvo61hwscFLxWVQ.csh) (3.0 KB)  
[mrggrid.abmp.capss2018.20181103.Cheongju30\_5km.log.txt](https://forum.cmascenter.org/uploads/short-url/8L6BeedTU3C2uDnYEvgBpZ48cAD.txt) (4.2 KB)

---

<div class="post-metadata">

**Author:** ![gwangjin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/gwangjin/32/1336_2.png) [@gwangjin](https://forum.cmascenter.org/u/gwangjin)\
**Post date:** [March 21, 2022, 1:05am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/2 "2022-03-21T01:05:14Z")

</div>

Is it impossible to merge `AGTS_L`, `NGTS_L` and `PGTS3D_L` in SMOKE v4.8.1? Or is this because the time dimension of `PGTS3D_L` does not match with `AGTS_L` and `NGTS_L`?

> ncdump -h pgts3d\_l.point.20181103.4.Cheongju30\_5km.capss2018.ncf  
> netcdf pgts3d\_l.point.20181103.4.Cheongju30\_5km.capss2018 {  
> dimensions:  
> TSTEP = UNLIMITED ; // (95 currently)  
> DATE-TIME = 2 ;  
> LAY = 17 ;  
> VAR = 45 ;  
> ROW = 120 ;  
> COL = 120 ;

> ncdump -h agts\_l.area.20181103.4.Cheongju30\_5km.capss2018.ncf  
> netcdf agts\_l.area.20181103.4.Cheongju30\_5km.capss2018 {  
> dimensions:  
> TSTEP = UNLIMITED ; // (96 currently)  
> DATE-TIME = 2 ;  
> LAY = 1 ;  
> VAR = 45 ;  
> ROW = 120 ;  
> COL = 120 ;

---

<div class="post-metadata">

**Author:** ![gwangjin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/gwangjin/32/1336_2.png) [@gwangjin](https://forum.cmascenter.org/u/gwangjin)\
**Post date:** [March 21, 2022, 2:47am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/3 "2022-03-21T02:47:02Z")

</div>

Oh, I found a solution.  
Adding the environment variable `PGTS3D_L` in `smk_mrgall.csh`

> setenv PGTS3D\_L /work/gwangjin/local/smoke\_v481/data/run\_capss2018/output/cmaq.saprc99pm/pgts3d\_l.point.20181103.4.Cheongju30\_5km.capss2018.ncf

I got the merged file I expected. Is this a bug?

---

<div class="post-metadata">

**Author:** ![bbaek](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/bbaek/32/22_2.png) [@bbaek](https://forum.cmascenter.org/u/bbaek)\
**Post date:** [March 21, 2022, 3:53am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/4 "2022-03-21T03:53:10Z")

</div>

Sorry for the late response. I was out of town with limited internet access. It is not a SMOKE bug but something to do with your SMOKE run scripts. You need to ensure that your PGTS3D\_L is set correctly for Smkmerge to open successfully. If you review your smk\_mrgall.csh script and understand how it works, you can assign the file to the right environment variable name.

---

<div class="post-metadata">

**Author:** ![gwangjin](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/gwangjin/32/1336_2.png) [@gwangjin](https://forum.cmascenter.org/u/gwangjin)\
**Post date:** [March 22, 2022, 4:11am UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/5 "2022-03-22T04:11:00Z")

</div>

Dear @bbaek,

There is a setenv of `PGT3D_L` in 37 line of $ASSIGNS/setmerge\_files.scr. But I found that  
it was defined only if $SMK\_SOURCE == ‘P’.

Should the setenv of `PGTS3D_L` be added in the line of 47 of `$ASSIGNS/setmerge_files.scr` for `SMK_SOURCE == E`?

[ASSIGNS.capss2018.cmaq.saprc99pm.Cheongju30\_5km.txt](https://forum.cmascenter.org/uploads/short-url/pGQcPRT9HinfXyVzjXEm7TBvDmb.txt) (23.4 KB)

---

<div class="post-metadata">

**Author:** ![bbaek](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.cmascenter.org/bbaek/32/22_2.png) [@bbaek](https://forum.cmascenter.org/u/bbaek)\
**Post date:** [March 22, 2022, 3:14pm UTC](https://forum.cmascenter.org/t/could-not-generate-individual-file-names-for-file-set-pgts3d-l/3105/6 "2022-03-22T15:14:59Z")

</div>

To merge files across multiple sectors using mrggrid, yes, you probably need to add that SMK\_SOURCE==E logic.
