We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1170abf commit 6da8be6Copy full SHA for 6da8be6
gpustat.py
@@ -401,7 +401,7 @@ def new_query():
401
return GPUStatCollection.new_query()
402
403
404
-def print_gpustat(**args):
+def print_gpustat(json=False, **args):
405
'''
406
Display the GPU query results into standard output.
407
@@ -430,7 +430,7 @@ def main():
430
help='Display PID of running process')
431
parser.add_argument('--gpuname-width', type=int, default=16,
432
help='The minimum column width of GPU names, defaults to 16')
433
- parser.add_argument('--json', action='store_true',
+ parser.add_argument('--json', action='store_true', default=False,
434
help='Print all the information in JSON format')
435
parser.add_argument('-v', '--version', action='version',
436
version=('gpustat %s' % __version__))
0 commit comments