Skip to content

Commit

Permalink
Feature #2772 python_embedding_tmp_file (#2807)
Browse files Browse the repository at this point in the history
Co-authored-by: Howard Soh <hsoh@seneca.rap.ucar.edu>
  • Loading branch information
hsoh-u and Howard Soh committed Feb 2, 2024
1 parent 06d7825 commit 4647a35
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions scripts/python/met/dataplane.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ def read_dataplane_json_numpy(tmp_filename):
numpy_dump_name = met_base_tools.get_numpy_filename(tmp_filename)
met_dp_data = np.load(numpy_dump_name)
met_info['met_data'] = met_dp_data
if numpy_dump_name != tmp_filename:
met_base_tools.remove_temp_file(numpy_dump_name)
return met_info

@staticmethod
Expand Down
2 changes: 1 addition & 1 deletion scripts/python/met/point.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ def read_point_data_json_numpy(self, tmp_filename):
self.obs_qty = point_array_list[11]

if numpy_dump_name != tmp_filename:
os.remove(numpy_dump_name)
met_base_tools.remove_temp_file(numpy_dump_name)

def write_point_data(self, tmp_filename):
if met_base_tools.use_netcdf_format():
Expand Down

0 comments on commit 4647a35

Please sign in to comment.