{"id":3731,"library":"paddlepaddle","title":"PaddlePaddle","description":"PaddlePaddle (PArallel Distributed Deep LEarning) is an efficient, flexible, and extensible deep learning framework. It is the first independent R&D deep learning platform in China, open-sourced since 2016, and is widely adopted across various industries including manufacturing, agriculture, and enterprise services. As of March 2026, the current stable version is 3.3.1. PaddlePaddle maintains regular updates for its core framework and offers monthly releases for its NVIDIA-optimized containers.","status":"active","version":"3.3.1","language":"en","source_language":"en","source_url":"https://github.com/PaddlePaddle/Paddle","tags":["deep learning","machine learning","AI","framework","GPU","distributed training","python"],"install":[{"cmd":"pip install paddlepaddle","lang":"bash","label":"CPU Version"},{"cmd":"pip install paddlepaddle-gpu","lang":"bash","label":"GPU Version (requires CUDA/cuDNN)"}],"dependencies":[{"reason":"Core numerical operations dependency.","package":"numpy","optional":false},{"reason":"Required for GPU version (e.g., CUDA 11.8 or 12.6 for recent PaddlePaddle versions on Linux; 10.2/11.2/11.6/11.7 on Windows).","package":"CUDA Toolkit","optional":true},{"reason":"Required for GPU version (e.g., cuDNN 7.6.5+).","package":"cuDNN","optional":true},{"reason":"Latest compatible driver for your GPU and CUDA version.","package":"NVIDIA GPU Driver","optional":true}],"imports":[{"symbol":"paddle","correct":"import paddle"}],"quickstart":{"code":"import paddle\n\n# Verify PaddlePaddle installation\nprint(f\"PaddlePaddle installation check: {'Success!' if paddle.utils.run_check() else 'Failed.'}\")\n\n# Create a tensor\nx = paddle.to_tensor([[1.0, 2.0], [3.0, 4.0]])\nprint(f\"\\nOriginal tensor:\\n{x}\")\n\n# Perform a simple operation (e.g., matrix multiplication)\ny = paddle.to_tensor([[5.0, 6.0], [7.0, 8.0]])\nz = paddle.matmul(x, y)\nprint(f\"Result of matrix multiplication:\\n{z}\")\n\n# Check if GPU is available and currently used\nif paddle.is_compiled_with_cuda():\n    print(f\"\\nCUDA is available. Current device: {paddle.get_device()}\")\nelse:\n    print(\"\\nCUDA is not available. Running on CPU.\")","lang":"python","description":"This quickstart code verifies the PaddlePaddle installation by running a built-in check. It then demonstrates basic tensor creation and a matrix multiplication operation, also indicating whether a GPU is detected and utilized."},"warnings":[{"fix":"Review the PaddlePaddle 2.0 Upgrade Guide and transition to the new API system, favoring dynamic graph mode. Explicitly enable static graph mode if needed via `paddle.enable_static()`.","message":"PaddlePaddle 2.0 introduced significant changes, making dynamic graph mode the default and adjusting the API directory system. While older APIs might be compatible, new development should adopt the updated API system for best practices and future compatibility.","severity":"breaking","affected_versions":"2.0 and later"},{"fix":"Always pin exact versions of `paddlepaddle` and any related sub-libraries (e.g., `paddleocr==X.Y.Z`) in your `requirements.txt` to prevent unforeseen issues from automatic updates. Regularly check release notes for breaking changes before upgrading.","message":"Sub-libraries or related projects within the PaddlePaddle ecosystem (e.g., PaddleOCR) have sometimes introduced breaking changes in minor or micro version updates, deviating from strict semantic versioning. This can lead to unexpected behavior if not pinning exact versions.","severity":"gotcha","affected_versions":"Various sub-library versions (e.g., PaddleOCR 2.6.0 to 2.6.1)"},{"fix":"Refer to the official PaddlePaddle installation guide for the exact CUDA, cuDNN, and driver versions compatible with your desired `paddlepaddle-gpu` version. Ensure your system meets all prerequisites before installation.","message":"Installing the GPU version (`paddlepaddle-gpu`) requires strict compatibility with your CUDA Toolkit, cuDNN, and NVIDIA GPU driver versions. Mismatches are a frequent source of installation failures or runtime errors.","severity":"gotcha","affected_versions":"All GPU versions"},{"fix":"Verify your Python interpreter and pip are 64-bit and meet the version requirements specified in the official installation documentation for your operating system. Use `python3 -c \"import platform; print(platform.architecture()[0]); print(platform.machine())\"` to check architecture and `python3 --version` and `python3 -m pip --version` for versions.","message":"PaddlePaddle has specific Python and pip version requirements. For example, Python 3.8-3.12 (or 3.9-3.13 on Linux) and pip 20.2.2+ are generally required, and the installation environment must be 64-bit.","severity":"gotcha","affected_versions":"All versions"}],"env_vars":null,"last_verified":"2026-04-11T00:00:00.000Z","next_check":"2026-07-10T00:00:00.000Z"}