MCPcopy Create free account
hub / github.com/apache/singa / image_transform

Function image_transform

python/singa/data.py:180–183  ·  view source on GitHub ↗
(img_path)

Source from the content-addressed store, hash-verified

178 tool = image_tool.ImageTool()
179
180 def image_transform(img_path):
181 global tool
182 return tool.load(img_path).resize_by_range((112, 128)).random_crop(
183 (96, 96)).flip().get()
184
185 data = ImageBatchIter('train.txt',
186 3,

Callers

nothing calls this directly

Calls 5

flipMethod · 0.80
random_cropMethod · 0.80
resize_by_rangeMethod · 0.80
getMethod · 0.45
loadMethod · 0.45

Tested by

no test coverage detected