Remote Assets
Remote media assets for examples and tutorials. Thin catalog that exposes image/video samples from DeGirum's PySDK Examples as simple attributes and lists.
Overview
degirum_tools.remote_assets is a tiny convenience module that discovers JPG images and MP4 videos published in the PySDK Examples repository and exposes them in two ways:
As dynamic attributes on the module:
remote_assets.<filename_without_extension>returns aRemoteMediaobject (astrsubclass with helpers) that behaves like a URL string.As enumerations:
list_images()andlist_videos()return dictionaries mapping attribute names toRemoteMediaobjects; use their keys to list available images/videos.
Each RemoteMedia instance is a URL-like string; remote_assets does not download or cache assets by itself. Any caching is handled by your application, HTTP stack, or PySDK internals.
When to Use
Quickstarts, demos, tests, and tutorials that need a stable sample image or video.
Prototyping code where you want to avoid bundling media assets in your repo.
Basic Usage
List available image and video asset names.
from degirum_tools import remote_assets
print("Images (names):")
print(sorted(list(remote_assets.list_images().keys())))
print("Videos (names):")
print(sorted(list(remote_assets.list_videos().keys())))Example output:
Images (names):
['bikes', 'car', 'cat', 'fire_place', 'license_plate', 'living_room', 'mask1', 'parking_lot', 'three_persons', 'two_cats']
Videos (names):
['cars_lp', 'example_video', 'faces_and_gender', 'hand_palm', 'parking', 'person_face_hand', 'person_pose', 'store', 'store_short', 'traffic', 'traffic2', 'traffic_hd', 'walking_people', 'walking_people2', 'walking_person']Fetch URLs for commonly used assets (a cat image and a walking‑people video).
from degirum_tools import remote_assets
# Access via attributes (preferred for readability)
cat_url = remote_assets.cat
walking_people_url = remote_assets.walking_people
print("cat:", cat_url)
print("walking_people:", walking_people_url)Example output:
cat: https://raw.githubusercontent.com/DeGirum/PySDKExamples/main/images/Cat.jpg
walking_people: https://raw.githubusercontent.com/DeGirum/PySDKExamples/main/images/WalkingPeople.mp4You can pass these URLs directly to PySDK models.
Functions
remote_assets.list_images() -> Dict[str, RemoteMedia]
Returns a mapping of attribute names (filename stems) to
RemoteMediaobjects for available JPG images.
remote_assets.list_videos() -> Dict[str, RemoteMedia]
Returns a mapping of attribute names (filename stems) to
RemoteMediaobjects for available MP4 videos.
Module Attributes
remote_assets.<name> -> RemoteMedia
Dynamic attribute corresponding to an asset filename without extension.
Returns a
RemoteMedia(subclass ofstr) pointing to a stable HTTPS URL for the asset in PySDK Examples.
RemoteMedia
RemoteMedia is a lightweight str subclass that adds simple media-type helpers while remaining usable anywhere a URL string is expected.
Attributes:
kind: media kind as a string, one of"image","video", or"other".is_image:Trueif the asset is an image.is_video:Trueif the asset is a video.
Example:
from degirum_tools import remote_assets
cat = remote_assets.cat # RemoteMedia (string URL with helpers)
print(cat) # prints the URL
print(cat.kind) # "image"
print(cat.is_image) # True
print(cat.is_video) # False
vid = remote_assets.walking_people
print(vid.kind) # "video"Example output:
https://raw.githubusercontent.com/DeGirum/PySDKExamples/main/images/Cat.jpg
image
True
False
videoLast updated
Was this helpful?

