Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions projects/amdsmi/amdsmi_cli/amdsmi_logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -620,9 +620,12 @@ def combine_arrays_to_json(self):
if self.store_partition_resources_json_output:
combined_json["partition_resources"] = self.store_partition_resources_json_output

self.destination == 'stdout'
json_std_output = json.dumps(combined_json, indent=4)
print(json_std_output)
if self.destination == 'stdout':
json_std_output = json.dumps(combined_json, indent=4)
print(json_std_output)
else:
with self.destination.open('w', encoding="utf-8") as output_file:
json.dump(combined_json, output_file, indent=4)


def _print_csv_output(self, multiple_device_enabled=False, watching_output=False):
Expand Down
Loading