AIPC Platform Python SDK

User Guide

  • Installation Guide
    • System Requirements
    • Dependencies
    • Installation Methods
      • Install from Source
      • Build a Wheel
      • GitHub Actions Wheel Artifacts
      • Planned Package Channels
    • Verify Installation
    • Development Environment
    • Docker Environment
    • Troubleshooting
      • Permission Issues
      • gRPC Connection Failure
      • Dependency Conflicts
  • Quick Start
    • Basic Concepts
    • First Application
    • Configuring Environment Variables
    • Core Feature Examples
      • AI Inference
        • Single-shot Inference
        • Streaming Inference
        • Model Management
      • Event Bus
        • Publish Events
        • Subscribe to Events
      • Device Control
        • Light Control
        • PTZ Control
        • GPIO Control
      • Video Stream Access
    • Error Handling
    • Logging
    • Next Steps
  • Application Image Build and Import Guide
    • Overview
    • Step 1: Prepare Application Files
      • Create Application Directory
      • Application Code (app.py)
      • Dockerfile
      • Application Manifest (app.yaml)
    • Step 2: Build the Docker Image
    • Step 3: Export the Image and Package a .neoapp
    • Step 4: Web Console Import (Recommended)
      • Open the Import Dialog
      • Screen 1 — Choose Source
      • Screen 2 — Configure the Application
      • Screen 3 — Install Progress
    • Step 5: Command Line Import (Alternative)
    • Application Manifest Reference (app.yaml)
      • Metadata
      • Resource Limits (spec.resources)
      • Permission Configuration (spec.permissions)
      • Lifecycle Configuration
      • Health Check
    • FAQ
      • Image Build Failure
      • Package Too Large
      • Import Failure
      • Permission Error
  • Examples
    • Person Detection Application
    • Vehicle Counting Application
    • Smart Light Control
    • Video Recording Application
    • Multi-Model Fusion Application

API Reference

  • AI Inference API
    • InferenceClient
    • Data Types
      • InferenceResult
      • BatchInferItem
        • BatchInferItem
      • DetectedObject
        • DetectedObject
      • BoundingBox
      • LandmarkPoint
        • LandmarkPoint
      • LandmarkSet
        • LandmarkSet
      • SegmentationMask
        • SegmentationMask
      • OcrLine
        • OcrLine
      • Embedding
        • Embedding
      • DepthMap
        • DepthMap
      • Classification
        • Classification
      • ModelInfo
        • ModelInfo
    • Usage Examples
      • Single-shot Inference
      • Streaming Inference
      • Tensor Inference
      • Model Management
      • Getting Statistics
      • Session Management
      • Handling Different Result Types
      • Context Manager
      • Error Handling
      • Segmentation Results
      • OCR Results
      • Embedding (CLIP Image)
      • CLIP Text Encoding
      • Depth Estimation
      • Update Postprocess Config
      • GenAI (LLM/VLM)
  • Video Stream API
    • FdMediaClient
    • Data Types
      • Frame
      • FrameHandle
        • FrameHandle
      • StreamInfo
        • StreamInfo
      • PixelFormat
        • PixelFormat
      • EncodedStreamClient
        • EncodedStreamClient
      • EncodedFrame
        • EncodedFrame
    • Usage Examples
      • Getting Raw Video Stream
      • No Frame Skipping
      • Getting a Single Frame
      • Getting Stream Info
      • Listing Available Streams
      • Frame Callback
      • Image Processing
      • Saving Images
      • Getting Encoded Stream
      • Multi-Stream Processing
      • Frame Rate Control
      • Saving Video
      • Context Manager
      • Zero-Copy Access
      • Error Handling
  • Event Bus API
    • EventClient
    • Data Types
      • Event
        • Event
      • TopicInfo
        • TopicInfo
    • Usage Examples
      • Publishing Events
      • Subscribing to Events
      • Using Callback Functions
      • Topic Wildcards
      • Listing Topics
      • Getting Statistics
      • Unsubscribing
      • Event Filtering
      • Context Manager
      • Error Handling
  • Device Control API
    • DeviceClient
    • Data Types
      • DeviceStatus
        • DeviceStatus
      • DeviceEvent
        • DeviceEvent
      • IrCutMode
        • IrCutMode
    • Usage Examples
      • Light Control
      • PTZ Control
      • Preset Control
      • Lens Control
      • GPIO Control
      • Wiegand Control
      • RS-485 Serial Control
      • Getting Device Status
      • Monitoring Device Events
      • Context Manager
      • Error Handling
  • Application Manager Client
    • AppInfo
      • AppInfo.id
      • AppInfo.name
      • AppInfo.version
      • AppInfo.state
      • AppInfo.container_id
      • AppInfo.pid
      • AppInfo.installed_at
      • AppInfo.started_at
      • AppInfo.stopped_at
      • AppInfo.restart_count
      • AppInfo.manifest_path
      • AppInfo.instance_path
      • AppInfo.__init__()
    • AppStats
      • AppStats.app_id
      • AppStats.cpu_usage_percent
      • AppStats.memory_usage_bytes
      • AppStats.memory_limit_bytes
      • AppStats.thread_count
      • AppStats.uptime_seconds
      • AppStats.__init__()
    • LogLine
      • LogLine.timestamp
      • LogLine.level
      • LogLine.message
      • LogLine.datetime
      • LogLine.__init__()
    • AppClient
      • AppClient.register_web_url()
      • AppClient.install_app()
      • AppClient.start_app()
      • AppClient.stop_app()
      • AppClient.uninstall_app()
      • AppClient.restart_app()
      • AppClient.list_apps()
      • AppClient.get_app()
      • AppClient.get_app_stats()
      • AppClient.get_logs()
      • AppClient.get_logs_text()
    • Usage Examples
      • Application Lifecycle
      • Getting Application Info
      • Viewing Application Logs
      • Registering Web URL
      • Context Manager
  • Configuration API
    • Config
      • Config
        • Config.get_app_id()
        • Config.get_inference_endpoint()
        • Config.get_event_bus_endpoint()
        • Config.get_device_control_endpoint()
        • Config.get_shm_base_path()
        • Config.get_camera_control_endpoint()
        • Config.get_app_manager_endpoint()
        • Config.get_encoded_socket_dir()
        • Config.get_host_prefix()
        • Config.translate_path_to_host()
        • Config.is_debug()
        • Config.get_log_level()
    • Usage Examples
      • Static Methods
      • Environment Variable Configuration
  • DSP Hardware Acceleration API
    • DspClient
      • DspBufferPool
        • DspBufferPool
      • DspError
        • DspError
      • PendingDspJob
        • PendingDspJob
    • Usage Examples
      • Full-frame resize (model input preprocessing)
      • Batched crops (letterbox scaling)
      • Single-region crop
      • Format conversion (RGB <-> NV12 / grayscale)
      • One-shot JPEG encode (snapshot / thumbnail)
      • Annotation blending (detection boxes onto NV12, dsp-offload P1)
      • Async jobs (submit now, wait later — dsp-offload P2)
      • Zero-copy blend chain (firmware-defect record: refused by default)
      • Pre-allocated buffer pool (repeated jobs)
      • Context manager
  • Camera Control API
    • CameraClient
    • Data Types
      • ISPConfig
        • ISPConfig
      • TransformConfig
        • TransformConfig
      • Capabilities
        • Capabilities
      • SensorInfo
        • SensorInfo
      • StreamStatus
        • StreamStatus
      • HardwareStatus
        • HardwareStatus
      • EnvStatus
        • EnvStatus
      • PipelineStreamConfig
        • PipelineStreamConfig
      • EncoderReconfigResult
        • EncoderReconfigResult
      • InfraredStatus
        • InfraredStatus
      • IrPreset
        • IrPreset
      • PrivacyMaskSettings
        • PrivacyMaskSettings
    • Usage Examples
      • ISP image adjustment
      • Image transform (flip / rotate / grayscale)
      • Infrared and night vision
      • Encoders and streams
      • Privacy mask
      • Environment and peripherals
      • Capability query
      • Context manager
  • Audio Control API
    • AudioClient
    • Data Types
      • AudioDevice
        • AudioDevice
      • AudioStatus
        • AudioStatus
    • Usage Examples
      • Query devices and status
      • Start / stop capture
      • Play a file (intercom playback)
      • Stream PCM (live intercom)
      • Volume and mute
      • Context manager
  • Audio Streaming API
    • AudioStreamClient
    • AudioFrame
      • AudioFrame
        • AudioFrame.codec
        • AudioFrame.flags
        • AudioFrame.pts_ns
        • AudioFrame.sample_rate
        • AudioFrame.channels
        • AudioFrame.bits_per_sample
        • AudioFrame.data
        • AudioFrame.dts_ns
        • AudioFrame.is_keyframe
        • AudioFrame.codec_name
        • AudioFrame.duration_ms
        • AudioFrame.__init__()
    • Usage Examples
      • Iterate audio frames
      • Fetch a single frame
      • Callback subscription
      • Raw PCM vs encoded frames
      • Error handling and cleanup
  • AI Overlay API
    • OverlayClient
    • OverlayConfig
      • OverlayConfig
        • OverlayConfig.enabled
        • OverlayConfig.show_label
        • OverlayConfig.show_confidence
        • OverlayConfig.line_thickness
        • OverlayConfig.box_color
        • OverlayConfig.label_color
        • OverlayConfig.font_size
        • OverlayConfig.to_proto()
        • OverlayConfig.__init__()
    • Usage Examples
      • Enable the overlay
      • Custom styling
      • Structured configuration
      • Combining with inference results (annotate)
      • Other result kinds
      • Context manager
  • Recording API
    • TsWriter
      • TsWriter
        • TsWriter.__init__()
        • TsWriter.write()
        • TsWriter.close()
    • HlsWriter
      • HlsWriter
        • HlsWriter.__init__()
        • HlsWriter.write()
        • HlsWriter.close()
    • PrerollBuffer
      • PrerollBuffer
        • PrerollBuffer.__init__()
        • PrerollBuffer.push()
        • PrerollBuffer.frames
        • PrerollBuffer.dump()
    • Usage Examples
      • Record MP4 (TsWriter)
      • HLS live segmentation
      • Preroll recording (pre-event cache)
      • Custom frame callback
  • Web Preview API
    • MjpegServer
    • MjpegStream
      • MjpegStream
        • MjpegStream.__init__()
        • MjpegStream.push_jpeg()
        • MjpegStream.push_frame()
        • MjpegStream.latest()
        • MjpegStream.latest_seq()
        • MjpegStream.wait_new()
    • mjpeg_wsgi_app
      • mjpeg_wsgi_app()
    • Usage Examples
      • Standalone MJPEG preview server
      • Push an existing JPEG
      • Inside a WSGI app (Flask / stdlib)
      • Low-latency latest-frame reads
  • Detection Drawing API
    • draw_boxes
      • draw_boxes()
    • draw_text
      • draw_text()
    • draw_detections
      • draw_detections()
    • draw_polygons
      • draw_polygons()
    • render_overlay_rgba
      • render_overlay_rgba()
    • Usage Examples
      • Draw boxes and labels
      • Draw arbitrary text
      • Render inference results directly
      • Polygons and tracks (zones / trajectory overlays, dsp-offload P2)
  • Color Conversion API
    • Functions
      • nv12_to_rgb / nv12_to_bgr
      • rgb_to_nv12 / bgr_to_nv12
      • nv12_resize
    • Examples
      • Feed an NV12 model with an RGB frame
      • Route through DSP hardware
  • Post-processing API
    • Functions
      • nms
    • Examples
      • Filter overlapping boxes after decoding
      • Through the accel router (switches to hardware NMS when exposed)
  • Accel Routing API
    • Classes and Functions
      • AccelRouter
      • RoutePolicy
      • RouteDecision / DegradationRecord
        • RouteDecision
        • DegradationRecord
      • get_default_router
    • Examples
      • Default router: hardware first, automatic fallback
      • Color conversion runs on the hardware leg too
      • JPEG encode: daemon one-shot RPC, CPU leg as fallback
      • Detection annotation: NV12 via DSP blend, RGB on the software raster
      • Forward degradations to the event bus
      • Hardware-only: fail instead of degrading
      • Capability probes
  • Plugin API
    • PluginDiscovery
      • PluginDiscovery
        • PluginDiscovery.__init__()
        • PluginDiscovery.reload()
        • PluginDiscovery.get()
        • PluginDiscovery.require()
        • PluginDiscovery.list_plugins()
        • PluginDiscovery.list_capabilities()
        • PluginDiscovery.watch()
        • PluginDiscovery.close()
    • PluginEndpoint
      • PluginEndpoint
        • PluginEndpoint.app_id
        • PluginEndpoint.capability_id
        • PluginEndpoint.version
        • PluginEndpoint.transport
        • PluginEndpoint.socket_path
        • PluginEndpoint.grpc_service
        • PluginEndpoint.event_publish
        • PluginEndpoint.event_subscribe
        • PluginEndpoint.state
        • PluginEndpoint.connect()
        • PluginEndpoint.is_available
        • PluginEndpoint.__init__()
    • PluginServer
      • PluginServer
        • PluginServer.__init__()
        • PluginServer.create_server()
        • PluginServer.start()
        • PluginServer.wait()
        • PluginServer.stop()
    • Usage Examples
      • App side: discover and call a plugin
      • Watch for plugin changes
      • Plugin side: advertise a capability
      • Hot reload

Other

  • Changelog
    • v0.8.0 (unreleased)
      • Deprecated
      • Documentation
    • v0.7.4 (2026-09-08)
      • New Features
      • Bug Fixes
    • v0.7.3 (2026-09-07)
      • New Features
      • Bug Fixes
    • v0.7.2 (2026-09-03)
      • Bug Fixes
    • v0.7.1 (2026-09-03)
    • v0.7.0 (2026-09-02)
      • New Features
      • Refactoring
      • Fixes
      • Other
    • v0.5.0 (2026-08-20)
      • Refactoring
      • Fixes
      • Other
    • v0.4.0 (2026-07-14)
      • New Features
      • Improvements
    • v0.3.0 (2026-05-18)
      • New Features
      • Improvements
      • Bug Fixes
    • v0.2.0 (2026-03-02)
      • New Features
      • Improvements
      • Bug Fixes
    • v0.1.0 (2025-12-15)
      • Initial Release
  • Contributing Guide
    • Development Environment Setup
    • Code Standards
    • Testing
    • Submitting Code
      • Commit Message Convention
    • Documentation
    • Reporting Issues
    • License
  • License
AIPC Platform Python SDK
  • Overview: module code

All modules for which code is available

  • neoruntime_ipc_sdk.accel
  • neoruntime_ipc_sdk.app
  • neoruntime_ipc_sdk.audio
  • neoruntime_ipc_sdk.audio_stream
  • neoruntime_ipc_sdk.camera
  • neoruntime_ipc_sdk.camera_types
  • neoruntime_ipc_sdk.color
  • neoruntime_ipc_sdk.config
  • neoruntime_ipc_sdk.device
  • neoruntime_ipc_sdk.draw
  • neoruntime_ipc_sdk.dsp
  • neoruntime_ipc_sdk.dsp_wire
  • neoruntime_ipc_sdk.encoded
  • neoruntime_ipc_sdk.events
  • neoruntime_ipc_sdk.fd_client
  • neoruntime_ipc_sdk.frame
  • neoruntime_ipc_sdk.inference
  • neoruntime_ipc_sdk.inference_types
  • neoruntime_ipc_sdk.overlay
  • neoruntime_ipc_sdk.plugin
  • neoruntime_ipc_sdk.postprocess
  • neoruntime_ipc_sdk.recording
  • neoruntime_ipc_sdk.web

© Copyright 2025-2026, CamThink.

Built with Sphinx using a theme provided by Read the Docs.