Errors occurred while creating GIS shapefile during the trajectory clustering using HYSPLIT model

Topics about the trajectory clustering program for HYSPLIT.
Post Reply
ankan29
Posts: 2
Joined: May 15th, 2023, 11:45 am
Registered HYSPLIT User: No

Errors occurred while creating GIS shapefile during the trajectory clustering using HYSPLIT model

Post by ankan29 »

Dear everyone,
By following the instructions given in HYSPLIT User's Guide and tutorial videos, I have successfully run the trajectory clustering using the HYSPLIT model installed on my Windows PC. The thing is, when I want to display cluster trajectories, the output file is only coming in an HTML file. But, when I click on the radio button 'GIS' to get output in the format which can be used to make a shapefile using Utilities>GIS to Shapefile, the following error comes:
error renaming "GIS_traj_ps_01.att": no such file or directory
error renaming "GIS_traj_ps_01.att": no such file or directory
while executing
"file rename -force GIS_traj_ps_01.att GIS_cluster${Nclus}_0${i}.att"
invoked from within
"if [file exists C${i}_${Nclus}.tdump] {
if { $PyPreferred } {
set arg_ext " "
if { $View_plot == 1 } { append arg_ext " --interactive"..."
(procedure "run_clusters" line 134)
invoked from within
"run_clusters 1 .clusdisp.lang"
invoked from within
".clusdisp.bot.save invoke"
("uplevel" body line 1)
invoked from within
"uplevel #0 [list $w invoke]"
(procedure "tk::ButtonUp" line 24)
invoked from within
"tk::ButtonUp .clusdisp.bot.save"
(command bound to event)
I am really clueless why the error is coming. When I did the same thing for one trajectory, the model was successfully creating 'GIS_traj_html_01.att' and 'GIS_traj_html_01.txt' files which I converted into shapefiles using Utilities>GIS to Shapefile. Can anyone please guide me to solve this issue? That will be very helpful for me. I am really looking forward to hearing from you. Thank you for your time and consideration.
With regards,
Ankan
sonny.zinn
Posts: 354
Joined: May 8th, 2019, 1:31 pm
Registered HYSPLIT User: Yes

Re: Errors occurred while creating GIS shapefile during the trajectory clustering using HYSPLIT model

Post by sonny.zinn »

Thank you for your post. The error occurred due to a software bug. Our next HYSPLIT release will fix the error.

In the meantime, the bug can be fixed by modifying one file. Using a text editor, open guicode/trajclus_disp.tcl. The guicode directory is found inside your hysplit installation directory. Replace _ps_ with _html_ on lines 367, 368

Code: Select all

     file rename -force GIS_traj_html_01.txt GIS_clusmeans${Nclus}-${ClusNo}_01.txt
     file rename -force GIS_traj_html_01.att GIS_clusmeans${Nclus}-${ClusNo}_01.att
and on lines 574, 575, 577, and 578:

Code: Select all

       if { $i < 10 } {
         file rename -force GIS_traj_html_01.att GIS_cluster${Nclus}_0${i}.att
         file rename -force GIS_traj_html_01.txt GIS_cluster${Nclus}_0${i}.txt
       } else {
         file rename -force GIS_traj_html_01.att GIS_cluster${Nclus}_${i}.att
         file rename -force GIS_traj_html_01.txt GIS_cluster${Nclus}_${i}.txt
       }
HYSPLIT Windows for "Display Means" and "Display Clusters" will need to be closed and opened again for the above changes to be effective. Alternatively, closing the whole HYSPLIT GUI and restarting it will work too.
ankan29
Posts: 2
Joined: May 15th, 2023, 11:45 am
Registered HYSPLIT User: No

Re: Errors occurred while creating GIS shapefile during the trajectory clustering using HYSPLIT model

Post by ankan29 »

Dear Sir,
Thank you for your response. I made the necessary changes in the guicode/trajclus_disp.tcl after opening in notepad as you suggested. But, still it didn't work. Can you provide a code (.bat file) which can be used to plot trajectory clusters so that I can run in the command prompt? The tutorial provided .bat file only for cluster mean. I want to display clusters. I am really looking forward to hearing from you. Thank you for your time and consideration.
With regards,
Ankan
sonny.zinn
Posts: 354
Joined: May 8th, 2019, 1:31 pm
Registered HYSPLIT User: Yes

Re: Errors occurred while creating GIS shapefile during the trajectory clustering using HYSPLIT model

Post by sonny.zinn »

Refer to https://www.ready.noaa.gov/documents/Tu ... _clus.html. Click the penguin icon under the section title for a Linux/macOS shell script. For Windows PC, use the terminal icon.

The GUI fix described above will be included in the next HYSPLIT release, probably within two months.
Post Reply

Return to “Cluster Analysis”