Image Action Set
Fetch Images Using SortBy
This example is not available for the CAS programming language.
Fetch Images Using SortBy
This example is not available for the Lua programming language.
Fetch Images Using SortBy
This section contains Python code. For more information about coding in Python, see Getting Started with SAS Viya for Python and SAS Viya: System Programming Guide.
The following Python uses the fetchImages action to fetch images from the table that is specified in the casOut parameter where the images are sorted by their _size_. Note that the fetchImages action fetches the images along with their width and height. If a label column is available in the table, that information is also copied to the final table. In addition, the fetchImagesVars parameter can be used to copy more columns from the input table.
s.image.fetchImages(
to=10,
fetchImagesVars=['_size_', '_path_'],
sortBy=[{'name':'_size_','order':'DESCENDING'}])
Fetch Images Using SortBy
This example is not available for the R programming language.