{"library":"pyrender","title":"Pyrender","description":"Pyrender is a pure Python library (compatible with Python 2.7, 3.4, 3.5, 3.6, though recent Python versions have known issues) for physically-based rendering and visualization. It adheres to the glTF 2.0 specification and provides both an interactive scene viewer and an offscreen renderer capable of GPU-accelerated rendering on headless servers, making it well-suited for machine learning applications. It is lightweight, easy to install, and designed for simplicity of use. The current version is 0.1.45, with development continuing on GitHub.","language":"python","status":"active","last_verified":"Sun May 17","install":{"commands":["pip install pyrender"],"cli":null},"imports":["import pyrender","import pyrender\nmesh = pyrender.Mesh(...)","import pyrender\nscene = pyrender.Scene(...)","import pyrender\nviewer = pyrender.Viewer(...)"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import trimesh\nimport pyrender\n\n# Load a mesh (e.g., a simple box)\nfuze_trimesh = trimesh.creation.icosphere()\nmesh = pyrender.Mesh.from_trimesh(fuze_trimesh)\n\n# Create a scene\nscene = pyrender.Scene()\nscene.add(mesh)\n\n# Add a camera\ncamera = pyrender.PerspectiveCamera(yfov=0.8, aspectRatio=1.0)\ncamera_pose = [1.0, 0.0, 0.0, 0.0,\n               0.0, 1.0, 0.0, 0.0,\n               0.0, 0.0, 1.0, 3.0,\n               0.0, 0.0, 0.0, 1.0]\nscene.add(camera, pose=camera_pose)\n\n# Add some lighting\nlight = pyrender.DirectionalLight(color=[1.0, 1.0, 1.0], intensity=3.0)\nlight_pose = [0.0, 0.0, 0.0, 0.0,\n              -0.5, 0.8, 0.0, 0.0,\n               0.0, 0.0, 1.0, 0.0,\n               0.0, 0.0, 0.0, 1.0]\nscene.add(light, pose=light_pose)\n\n# View the scene\npyrender.Viewer(scene, use_raymond_lighting=True)","lang":"python","description":"This quickstart demonstrates how to load a basic mesh using `trimesh`, add it to a Pyrender scene, set up a camera and lighting, and then display the scene in an interactive viewer. For offscreen rendering, a `pyrender.OffscreenRenderer` would be used instead of `pyrender.Viewer`.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":{"tag":null,"tag_description":null,"last_tested":"2026-05-17","installed_version":"0.1.45","pypi_latest":"0.1.45","is_stale":false,"summary":{"python_range":"3.10–3.9","success_rate":100,"avg_install_s":14.9,"avg_import_s":null,"wheel_type":"sdist"},"results":[{"runtime":"python:3.10-alpine","python_version":"3.10","os_libc":"alpine (musl)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"308.1M"},{"runtime":"python:3.10-slim","python_version":"3.10","os_libc":"slim (glibc)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":14.5,"import_time_s":null,"mem_mb":null,"disk_size":"299M"},{"runtime":"python:3.11-alpine","python_version":"3.11","os_libc":"alpine (musl)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"333.4M"},{"runtime":"python:3.11-slim","python_version":"3.11","os_libc":"slim (glibc)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":13.5,"import_time_s":null,"mem_mb":null,"disk_size":"323M"},{"runtime":"python:3.12-alpine","python_version":"3.12","os_libc":"alpine (musl)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"315.8M"},{"runtime":"python:3.12-slim","python_version":"3.12","os_libc":"slim (glibc)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":15.6,"import_time_s":null,"mem_mb":null,"disk_size":"305M"},{"runtime":"python:3.13-alpine","python_version":"3.13","os_libc":"alpine (musl)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"314.5M"},{"runtime":"python:3.13-slim","python_version":"3.13","os_libc":"slim (glibc)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":14.8,"import_time_s":null,"mem_mb":null,"disk_size":"304M"},{"runtime":"python:3.9-alpine","python_version":"3.9","os_libc":"alpine (musl)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":"307.6M"},{"runtime":"python:3.9-slim","python_version":"3.9","os_libc":"slim (glibc)","variant":"pyrender","exit_code":0,"wheel_type":"sdist","failure_reason":null,"import_side_effects":"broken","install_time_s":16,"import_time_s":null,"mem_mb":null,"disk_size":"304M"}]}}