Skip to content

[Feature] centralized Python tests and default to single-process pytest to avoid CUDA OOM #1146

@viiccwen

Description

@viiccwen

What

  • Move QDP Python tests from qdp/qdp-python/tests/ to testing/qdp_python/ so all Python tests live under the top-level testing/ tree and are run by make test_python / root pytest.
  • Change the default Python test run to single-process (no -n auto) to avoid CUDA out-of-memory and flakiness when multiple workers use the GPU; document that users with sufficient compute can optionally use -n auto or -n N to speed up.

Why

  1. Test location: QDP Python tests live under qdp/qdp-python/tests/, while the rest of the Python suite is under testing/ (e.g. testing/qumat, testing/qdp). Root pytest uses testpaths = ["testing"], so the qdp-python tests were not discovered by the default make test_python run unless invoked from the right place or with an extra path.
  2. Parallelism: Running the full suite with -n auto can cause CUDA OOM or instability when several workers use the GPU. A single-process default is safer; users who have enough GPU memory and want faster runs should be able to opt in to parallelism via documentation.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions