Performance Optimization
Performance Overview
Client Type
Typical Performance
Best Use Case
Async Client Optimization
1. Choose the Right Mode
from uesynth import AsyncUESynthClient
# ๐ Streaming mode - highest performance
async def streaming_mode():
async with AsyncUESynthClient() as client:
# Non-blocking operations
request_id = await client.capture.rgb() # Returns immediately
frame = await client.get_latest_frame() # Get when ready
# ๐ Direct mode - medium performance, easier to use
async def direct_mode():
async with AsyncUESynthClient() as client:
# Blocking operations
frame = await client.capture.rgb_direct() # Waits for result2. Optimize Buffer Settings
3. Batch Operations
Network Optimization
1. Compression
2. Image Resolution
3. Network Configuration
Memory Optimization
1. Frame Management
2. Capture Only What You Need
CPU Optimization
1. Concurrent Processing
2. Optimize Frame Processing
Real-Time Optimization
1. Frame Rate Management
2. Predictive Frame Requests
Benchmarking and Monitoring
1. Performance Measurement
2. Resource Monitoring
Configuration Recommendations
Development Environment
Production Environment
High-Throughput Scenarios
Troubleshooting Performance
Common Issues and Solutions
Next Steps
Last updated