MCPcopy Create free account
hub / github.com/NVIDIA/vid2vid / print_numpy

Function print_numpy

util/util.py:132–139  ·  view source on GitHub ↗
(x, val=True, shp=False)

Source from the content-addressed store, hash-verified

130 image_pil.save(image_path)
131
132def print_numpy(x, val=True, shp=False):
133 x = x.astype(np.float64)
134 if shp:
135 print('shape,', x.shape)
136 if val:
137 x = x.flatten()
138 print('mean = %3.3f, min = %3.3f, max = %3.3f, median = %3.3f, std=%3.3f' % (
139 np.mean(x), np.min(x), np.max(x), np.median(x), np.std(x)))
140
141def mkdirs(paths):
142 if isinstance(paths, list) and not isinstance(paths, str):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected