Open Source Development

Power Open Source Development

Explore the open source tools and capabilities for building and deploying modern applications on IBM Power platforms including AIX, IBM i, and Linux.


#Power


#Power

 View Only
Expand all | Collapse all

Unleash the power of AI with optimized Python packages for IBM Power!

  • 1.  Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Thu August 07, 2025 12:21 PM
    Edited by Gerrit Huizenga Thu August 07, 2025 12:25 PM

    The IBM Linux on Power team is thrilled to announce the availability of optimized wheels for Python! While Python is theoretically an architecture-independent language, most know that the distribution packages for wheels often include optimized components built with other languages. Starting now, IBM is building a subset of these open source Python packages natively on Power for you and making them available via a DevPi server. These wheels have been selected based on various AI projects in progress around the Power brand and should represent a healthy base set of packages for anyone looking to do Python based development natively on IBM Power9, IBM Power10, and IBM Power11 servers.

    There are a couple of other blogs with details on how to get access, so here we'll just include the basics for now to get you going. The very first is that we'll strongly recommend using Python 3.10, 3.11 or 3.12, and within those, you'll typically see Python 3.11 and 3.12 currently have the greatest number of packages and versions available. We also highly recommend using $ python3.12 -m venv venv to create and use a local virtual environment when working with pip. Pip's dependency resolver attempts to work major magic, and it is simplest to contain it to a virtual environment to minimize the number of dependencies it might find and constraints it tries to work through. Once you have a virtual environment, we strongly recommend the use of the pip flag --prefer-binary which tells the dependency resolver to prefer applications which have been compiled to work on this platform, which ensures that it will work to pull from our wheel repository.

    The wheel repository is located at: https://wheels.developerfirst.ibm.com, and a pip install line might be:

    $ pip install –prefer-binary vllm –extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux

    Note that –extra-index-url specifies where to look in addition to pypi.org. Any noarch dependencies are fetched from pypi.org in this case.

    The server is a DevPi server. In addition to accessing the wheels as you normally would with pip, you can also install devpi-client locally (it is pip/pipx installable) and then run:

    $ devpi use https://wheels.developerfirst.ibm.com/ppc64le/linux

    $ devpi list

    And devpi will return a list of all packages in the repository. This set of packages will typically be able to resolve against most major packages either with Power specific package in this repo or from the noarch packages from pypi.org. However, if you have issues where something does not resolve correctly, drop us a comment on the TechXchange community and we'll investigate it. We can't solve issues that aren't solved on PyPI, and sometimes the constraints will get complex, but we do have some practice and may be able to help untangle or provide a fix.

     You might wonder why we created a whole new repository rather than updating the packages on pypi.org to directly support Power. That's an excellent question, and our gold standard is to be fully integrated upstream. However, that level of integration has a number of challenges which we are working through as some of you have already seen. For instance, we clearly need a well-integrated, upstream CI/CD, and for that we recently added GitHub Actions for Power (and IBM Z and LinuxOne!) to our options, it will take a while to get upstream open source migrated. Also, managing versions, optimizations, testing, dependencies, etc. are all activities that take either our team or upstream/our team bandwidth, and that is always done with the community in collaboration, which can take time. In short, to provide a broader set of access quickly, we felt it easiest to set up a repository for wheels.

    We expect this list to evolve over time, generally based on active AI projects. While we aren't formally set up for taking requests, you are welcome to put suggestions in the comments here where we will occasionally review and determine what additional packages or versions we may add. We are hoping to add support for Python 3.13 in due time, depending on when Python 3.13 is released with RHEL. Also, additional versions may be added based on our needs.

    Our goal is to enable Power customers to use Python and evaluate how they can get the most value from their systems. The blending of the large data that Power servers typically have access to, its ability to process massive amounts of data, and Python and optimized libraries should provide some steppingstones for data analysis, deep learning, machine learning, generative AI and agentic AI.

    This is a new, first of a kind activity for us and we are really interested in your feedback. Drop us a line about what you will do with Python on IBM Power.

    Check out these blogs to know what our incredible development team has been doing:

    Many thanks to our development team that built the infrastructure and completed the ports of these packages to Power.



    ------------------------------
    Gerrit
    ------------------------------


    #OpenSourceDevelopment


  • 2.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 08, 2025 12:38 PM

    Congratulations on this achievement! 



    ------------------------------
    Lance Albertson
    Director
    Oregon State University
    Corvallis OR
    ------------------------------



  • 3.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Tue August 12, 2025 09:46 AM
    Edited by Jack Woehr Tue August 12, 2025 09:49 AM

    $ uname -a
    Linux oph6 6.8.0-71-generic #71-Ubuntu SMP Tue Jul 22 17:05:44 UTC 2025 ppc64le ppc64le ppc64le GNU/Linux
    $ cat /etc/os-release
    PRETTY_NAME="Ubuntu 24.04.3 LTS"
    NAME="Ubuntu"
    VERSION_ID="24.04"
    VERSION="24.04.3 LTS (Noble Numbat)"
    VERSION_CODENAME=noble
    ID=ubuntu
    ID_LIKE=debian
    HOME_URL="https://www.ubuntu.com/"
    SUPPORT_URL="https://help.ubuntu.com/"
    BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
    PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
    UBUNTU_CODENAME=noble
    LOGO=ubuntu-logo
    $ pip install –prefer-binary vllm –extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux
    ERROR: Invalid requirement: '–prefer-binary'
    Any tips, @Gerrit Huizenga?


    #OpenSourceDevelopment


  • 4.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Tue August 12, 2025 01:17 PM
    Several - first: Ubuntu?!  Oh no prob that should work.  :). Second can you check your version of python, third can you create a venv (python3.12 -m venv venv) and activate it, then upgrade pip.  That should  fix it.  My guess is it is an older version of python but just guessing?

    Gerrit





  • 5.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Tue August 12, 2025 01:36 PM
    Edited by Jack Woehr Tue August 12, 2025 02:47 PM

    I figured it out.

    The editor turned your dash-dash in an emdash.

    did notice there appeared to be just one dash.

    So I added an extra dash to your options.

    But that left me with "dash emdash" which pip didn't recognize.

    I deleted your emdash and typed in two dashes and now it is installing ...

    Stupid editor software! When we say CODE we mean CODE !!! :)

    >FWIW here is the corrected command line:
    pip install --prefer-binary vllm --extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 6.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Tue August 12, 2025 01:39 PM

    I did not guess emdash.  I will add that to my list of oddities to check in the future.  :). 

    gerrit



    ------------------------------
    Gerrit
    ------------------------------



  • 7.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Sat August 16, 2025 10:14 PM

    But when I try to run vllm the following happens:

    $ vllm --help
    Traceback (most recent call last):
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/bin/vllm", line 5, in <module>
        from vllm.entrypoints.cli.main import main
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/__init__.py", line 10, in <module>
        import vllm.env_override  # isort:skip  # noqa: F401
        ^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/env_override.py", line 4, in <module>
        import torch
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/torch/__init__.py", line 409, in <module>
        from torch._C import *  # noqa: F403
        ^^^^^^^^^^^^^^^^^^^^^^
    ImportError: libprotobuf.so.25.3.0: cannot open shared object file: No such file or directory



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 8.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Sun August 17, 2025 07:26 PM
    Hi Jack

    Have you tried searching for libprotobuf? You may need to install the package.
    https://open-source-edge.developerfirst.ibm.com/search-packages/libprotobuf9v5

    Hope this helps.

    Thanks,

    Paul


    ------------------------------
    PAUL BASTIDE
    Senior Software Engineer
    IBM
    ------------------------------



  • 9.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Sun August 17, 2025 08:28 PM

    Yes, that was my first thought. It's installed.



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 10.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 03:05 PM

    Hi Jack,

    I was able to replicate the libprotobuf error for vllm. It seems to be associated with the pytorch install.

    When I run ldd on the lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so file, I get these errors (I masked the full path using __prefix__):

    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.33' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `CXXABI_1.3.13' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libshm.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `CXXABI_1.3.13' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libm-2.28.so: version `GLIBC_2.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.33' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libm-2.28.so: version `GLIBC_2.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so)
    __prefix__/vllm/lib/python3.12/site-packages/torch/_C.cpython-312-powerpc64le-linux-gnu.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so)
            linux-vdso64.so.1 (0x0000200000060000)
            libtorch_python.so => __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_python.so (0x00002000000d0000)
            libtorch.so => __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch.so (0x0000200001540000)
            libshm.so => __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libshm.so (0x0000200001590000)
            libtorch_cpu.so => __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so (0x00002000015e0000)
            libprotobuf.so.25.3.0 => not found
            libc10.so => __prefix__/vllm/lib/python3.12/site-packages/torch/lib/libc10.so (0x000020000a120000)
            libstdc++.so.6 => /lib64/libstdc++.so.6 (0x000020000a290000)
            libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x000020000a4c0000)
            libc.so.6 => /lib64/glibc-hwcaps/power9/libc-2.28.so (0x000020000a500000)
            /lib64/ld64.so.2 (0x0000200000000000)
            libprotobuf.so.25.3.0 => not found
            libm.so.6 => /lib64/glibc-hwcaps/power9/libm-2.28.so (0x000020000a710000)
            libprotobuf.so.25.3.0 => not found
            libopenblas.so.0 => not found
            libgomp.so.1 => /lib64/libgomp.so.1 (0x000020000a840000)
            libdl.so.2 => /lib64/libdl.so.2 (0x000020000a8b0000)
            libpthread.so.0 => /lib64/glibc-hwcaps/power9/libpthread-2.28.so (0x000020000a8e0000)

    We are running Alma Linux 8.10 on our power machines.

    I indeed also have libprotobuf installed, including the devel headers. Our system provides libprotobuf.so.15.0.0 so it could be a version incompatibility issue.

    I see a new version of libprotobuf available on the open source edge page but I don't see any way to access it from my package manager:

    According to the build script, we may need to be on a UBI 9 compatible system instead. We are on Alma 8 so we can install nvidia drivers, if I recall correctly.

    Seems like maybe I should try installing in a container instead.

    Ed



    ------------------------------
    Edward Davis
    ------------------------------



  • 11.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 03:32 PM
    We have the dev team looking into this one as well.  Our testing was very constrained for this round so we could get as much out as soon as possible, so I'm not ruling out issues on our side.  We definitely wouldn't have tested Alma, but I can't think why it wouldn't work in a virtual env anyway - all of the dependencies should be located in the venv.   Do you have a requirements.txt that you are using to install that we could evaluate?  We used a number of real life workloads to build the package set and within each workload we know that the package set is consistent, but as you add packages, versions, dependencies, it is easy to get things that may not resolve.  But we did do a fair bit of testing to ensure that as much as possible is consistent, but we may have more polishing to do here.  Or it may be a use case that we hadn't planned for or tested.

    gerrit





  • 12.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 04:48 PM

    Here's what I did to get here:

    uv venv --seed vllm-py3.12 -p 3.12
    source vllm-py3.12/bin/activate
    CC=gcc CXX=g++ python -m pip install --prefer-binary --extra-index-url https://wheels.developerfirst.ibm.com/ppc64le/linux vllm
    

    I had to compile the uvloop package from source, but I'm not sure that's relevant.

    Here is the output of pip freeze:

    aiohappyeyeballs==2.6.1
    aiohttp==3.12.15
    aiosignal==1.4.0
    annotated-types==0.7.0
    anyio==4.10.0
    astor==0.8.1
    attrs==25.3.0
    blake3==1.0.5
    cachetools==6.1.0
    certifi==2025.8.3
    charset-normalizer==3.4.3
    click==8.2.1
    cloudpickle==3.1.1
    compressed-tensors==0.9.3
    datasets==4.0.0
    Deprecated==1.2.18
    depyf==0.18.0
    dill==0.3.8
    distro==1.9.0
    dnspython==2.7.0
    einops==0.8.1
    email_validator==2.2.0
    fastapi==0.116.1
    fastapi-cli==0.0.8
    fastapi-cloud-cli==0.1.5
    filelock==3.19.1
    frozenlist==1.7.0
    fsspec==2025.3.0
    gguf==0.17.1
    googleapis-common-protos==1.70.0
    grpcio==1.71.0
    h11==0.16.0
    httpcore==1.0.9
    httptools==0.6.4
    httpx==0.28.1
    huggingface-hub==0.34.4
    idna==3.10
    importlib_metadata==8.0.0
    interegular==0.3.3
    Jinja2==3.1.6
    jiter==0.10.0
    jsonschema==4.25.1
    jsonschema-specifications==2025.4.1
    lark==1.2.2
    lm-format-enforcer==0.10.12
    markdown-it-py==4.0.0
    MarkupSafe==3.0.2
    mdurl==0.1.2
    mistral_common==1.8.3
    mpmath==1.3.0
    msgspec==0.19.0
    multidict==6.6.4
    multiprocess==0.70.16
    networkx==3.5
    ninja==1.13.0
    numpy==2.3.1
    openai==1.100.0
    opencv-python-headless==4.11.0.86
    opentelemetry-api==1.26.0
    opentelemetry-exporter-otlp==1.26.0
    opentelemetry-exporter-otlp-proto-common==1.26.0
    opentelemetry-exporter-otlp-proto-grpc==1.26.0
    opentelemetry-exporter-otlp-proto-http==1.26.0
    opentelemetry-proto==1.26.0
    opentelemetry-sdk==1.26.0
    opentelemetry-semantic-conventions==0.47b0
    opentelemetry-semantic-conventions-ai==0.4.12
    packaging==25.0
    pandas==2.2.3
    partial-json-parser==0.2.1.1.post6
    pillow==11.2.1
    prometheus-fastapi-instrumentator==7.1.0
    prometheus_client==0.22.1
    propcache==0.3.2
    protobuf==4.25.8
    psutil==7.0.0
    py-cpuinfo==9.0.0
    pyarrow==19.0.1
    pycountry==24.6.1
    pydantic==2.11.7
    pydantic-extra-types==2.10.5
    pydantic_core==2.33.2
    Pygments==2.19.2
    python-dateutil==2.9.0.post0
    python-dotenv==1.1.1
    python-json-logger==3.3.0
    python-multipart==0.0.20
    pytz==2025.2
    PyYAML==6.0.2
    pyzmq==26.4.0
    referencing==0.36.2
    regex==2025.7.34
    requests==2.32.4
    rich==14.1.0
    rich-toolkit==0.15.0
    rignore==0.6.4
    rpds-py==0.27.0
    safetensors==0.6.2
    scipy==1.16.0
    sentencepiece==0.2.0
    sentry-sdk==2.35.0
    setuptools==80.9.0
    shellingham==1.5.4
    six==1.17.0
    sniffio==1.3.1
    starlette==0.47.2
    sympy==1.14.0
    tiktoken==0.7.0
    tokenizers==0.21.4
    torch==2.7.1
    tqdm==4.67.1
    transformers==4.55.2
    typer==0.16.1
    typing-inspection==0.4.1
    typing_extensions==4.14.1
    tzdata==2025.2
    urllib3==2.5.0
    uvicorn==0.35.0
    uvloop==0.21.0
    vllm==0.8.4+cpu
    watchfiles==1.1.0
    websockets==15.0.1
    wrapt==1.17.3
    xxhash==3.5.0
    yarl==1.20.1
    zipp==3.23.0

    To simplify troubleshooting, I made this minimal example:

    uv venv --seed pytorch -p 3.12
    source pytorch/bin/activate
    python -m pip install --prefer-binary --extra-index-url https://wheels.developerfirst.ibm.com/ppc64le/linux torch

    And import torch to reproduce the error:

    ➜ python -c 'import torch'
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/nfs4/core/scratch/davised/pytorch/lib/python3.12/site-packages/torch/__init__.py", line 409, in <module>
        from torch._C import *  # noqa: F403
        ^^^^^^^^^^^^^^^^^^^^^^
    ImportError: libprotobuf.so.25.3.0: cannot open shared object file: No such file or directory

    Here is the freeze output:

    filelock==3.19.1
    fsspec==2025.7.0
    Jinja2==3.1.6
    MarkupSafe==3.0.2
    mpmath==1.3.0
    networkx==3.5
    setuptools==80.9.0
    sympy==1.14.0
    torch==2.7.1
    typing_extensions==4.14.1

    Cheers,

    Ed



    ------------------------------
    Edward Davis
    Bioinformatics Manager
    Oregon State University
    Corvallis OR
    ------------------------------



  • 13.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 22, 2025 11:25 AM

    Edward, you might check at my response to Jack as well - it may be that this will help with your case as well?

    gerrit



    ------------------------------
    Gerrit
    ------------------------------



  • 14.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 22, 2025 10:24 AM

    Hey Jack, not sure if you solved this one, but I want to point out one item I missed in my testing that is in Nikhil's blog:

    If a package has dependencies on any libraries such as libprotobuf or libopenblas (for example, pytorch has a dependency on libprotobuf), then it is expected to explicitly install libprotobuf wheel from IBM Python Wheel Repository and set LD_LIBRARY_PATH environment variable accordingly.

    Example

    pip install --prefer-binary libprotobuf==4.25.3 torch==2.6.0 --extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux

    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib:/opt/venv/lib/python3.12/site-packages/libprotobuf/lib64

    For some packages you do need to explicitly set and export LD_LIBRARY_PATH.  My testing didn't run over a case that needed it so I missed it.

    I'll update my blog to be more clear about this as well.  And sorry that took so long for us to figure out - we are spinning a lot of plates.  The initial release of this was for us the culmination of a lot of work that we wanted to get out to people as soon as possible, but we do know that there's going to be a fair bit of work to polish this up, we have a lot of plans for evolving this to make it simpler, maintain currency of packages, add packages, update versions of python, update our UI, just as a few teasers, so just because we've made a few boo boos on launch, don't give up on us!  We have much, much more fun planned!  :)

    gerrit



    ------------------------------
    Gerrit
    ------------------------------



  • 15.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 22, 2025 11:19 AM

    Thanks for getting back to me on this @Gerrit Huizenga ... I'll give that a try. I understand VLLM is the way going forward for LLM support on PowerLinux?



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 16.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 22, 2025 11:24 AM

    Ha - that's an easy, and a hard question.  Today, absolutely!  We've been heavily focused there.  But this industry is very dynamic right now and we are trying to keep up as best as possible, so we do look at making sure ollama is available, as well as other tooling and such.  We are trying to be interlocked with our IBM offerings but also disconnected enough that you can DIY things based on where the industry is hot.  We obviously will have some lag making things available but this python ecosystem launch is intended to make us a fair bit more nimble here and react as best as possible to the industry directions while aligning with IBM products and our ISV offerings.  It's a fun path! ;)



    ------------------------------
    Gerrit
    ------------------------------



  • 17.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 25, 2025 08:53 AM

    Starting from your response, @Gerrit Huizenga:

    $ pip install --prefer-binary libprotobuf==4.25.3 torch==2.6.0 --extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux
    ....
    $ vllm --help

    Traceback (most recent call last):
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/bin/vllm", line 5, in <module>
        from vllm.entrypoints.cli.main import main
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/__init__.py", line 10, in <module>
        import vllm.env_override  # isort:skip  # noqa: F401
        ^^^^^^^^^^^^^^^^^^^^^^^^
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/env_override.py", line 4, in <module>
        import torch
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/torch/__init__.py", line 405, in <module>
        from torch._C import *  # noqa: F403
        ^^^^^^^^^^^^^^^^^^^^^^
    ImportError: libprotobuf.so.25.8.0: cannot open shared object file: No such file or directory
    $ locate libprotobuf.so
    /home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/libprotobuf/lib64/libprotobuf.so
    /home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/libprotobuf/lib64/libprotobuf.so.25.3.0
    /usr/lib/powerpc64le-linux-gnu/libprotobuf.so
    /usr/lib/powerpc64le-linux-gnu/libprotobuf.so.32
    /usr/lib/powerpc64le-linux-gnu/libprotobuf.so.32.0.12
    So then:
    pip install --prefer-binary libprotobuf==4.25.8

    Then it failed for libopenblas, which I installed (apt install libopenblas-dev)
    Then it fails for the specific version libjpeg.so.62 which is not satisfied after apt install libjpeg-dev.
    $ vllm --help
    Traceback (most recent call last):
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/bin/vllm", line 5, in <module>
        from vllm.entrypoints.cli.main import main
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/__init__.py", line 12, in <module>
        from vllm.engine.arg_utils import AsyncEngineArgs, EngineArgs
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/engine/arg_utils.py", line 16, in <module>
        from vllm.config import (CacheConfig, CompilationConfig, ConfigFormat,
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/vllm/config.py", line 25, in <module>
        from transformers import PretrainedConfig
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/transformers/__init__.py", line 27, in <module>
        from . import dependency_versions_check
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/transformers/dependency_versions_check.py", line 16, in <module>
        from .utils.versions import require_version, require_version_core
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/transformers/utils/__init__.py", line 37, in <module>
        from .chat_template_utils import DocstringParsingException, TypeHintParsingException, get_json_schema
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/transformers/utils/chat_template_utils.py", line 50, in <module>
        from PIL.Image import Image
      File "/home/jwoehr/work/AI/VLLM/vllm_venv/lib/python3.12/site-packages/PIL/Image.py", line 90, in <module>
        from . import _imaging as core
    ImportError: libjpeg.so.62: cannot open shared object file: No such file or directory




    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 18.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 22, 2025 04:29 PM

    Hi Gerrit,

    I added these snippets to my venv activate script:

    # within the deactivate function
        if ! [ -z "${_OLD_LD_LIB+_}" ] ; then
            LD_LIBRARY_PATH="$_OLD_LD_LIB"
            unset _OLD_LD_LIB
        fi
    
    # below the $PATH setting
    _OLD_LD_LIB="$LD_LIBRARY_PATH"
    if [ -e "$VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64" ]; then
        LD_LIBRARY_PATH="${LD_LIBRARY_PATH:+${LD_LIBRARY_PATH}:}$VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64"
        export LD_LIBRARY_PATH
    fi

    and that indeed did resolve the libprotobuf errors.

    However, I still have these (I manually masked the full path using $VIRTUAL_ENV):

    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.33' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `CXXABI_1.3.13' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libshm.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `CXXABI_1.3.13' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libm-2.28.so: version `GLIBC_2.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.33' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_cpu.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.33' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libprotobuf.so.25.3.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libprotobuf.so.25.3.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libm-2.28.so: version `GLIBC_2.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libc10.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libc10.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libc10.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libc10.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libc10.so)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_log_internal_message.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_vlog_config_internal.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_status.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_cord.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libm-2.28.so: version `GLIBC_2.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_exponential_biased.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_synchronization.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_time_zone.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_crc_cord_state.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_malloc_internal.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_str_format_internal.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so: /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.32' not found (required by $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_base.so.2401.0.0)
    $VIRTUAL_ENV/lib/python3.12/site-packages/torch/lib/libtorch_python.so:
    /lib64/glibc-hwcaps/power9/libc-2.28.so: version `GLIBC_2.34' not found
    (required by
    $VIRTUAL_ENV/lib/python3.12/site-packages/libprotobuf/lib64/libabsl_base.so.2401.0.0)

    My gcc version is this:

    ➜ gcc --version
    gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-22)
    Copyright (C) 2018 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions.  There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

    I can probably get an updated gcc using conda to resolve this issue.



    ------------------------------
    Edward Davis
    Bioinformatics Manager
    Oregon State University
    Corvallis OR
    ------------------------------



  • 19.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 10:48 AM

    Hi Gerrit,

    I'm getting a 404 when trying to view the wheels on the web and they aren't being found on the cli when I specify the index as described. 

    Am I missing a key step here? 

    Thanks, 

    Ed



    ------------------------------
    Edward Davis
    ------------------------------



  • 20.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 11:02 AM
    Hi Edward,

    Not sure what happened, and I'm guessing but did you prepend https:// to the devpi use line before wheels.developerfirst.ibm.com?

    I tried without that and got a 404.  I thought I might have left something out on the blog (or maybe someone updated for me ;) ) but that's what I would check first.  Otherwise I might need to see your full lines run, e.g. the equivalent of what is in the blog.   I just double check after a week of vacation and verified that the server is still running.  Let us know though if there are still issues - devpi is definitely working but I'm chasing another rumor of a 404 so there may be some routing or other issue but in general it seems accessible.

    gerrit





  • 21.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 12:17 PM

    BTW, Edward, the devpi index isn't http/https scannable - it is only pip/devpi accessible.  It isn't a pypi(tm) server.

    gerrit



    ------------------------------
    Gerrit
    ------------------------------



  • 22.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 18, 2025 12:59 PM

    Hi Gerrit,

    Ok I got the devpi part to work, and then I found that the package I was trying to install (vllm) required 3.12 rather than the 3.11 that I had installed.

    Cheers,

    Ed



    ------------------------------
    Edward Davis
    ------------------------------



  • 23.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon August 25, 2025 10:48 AM

    Below steps worked for me, tested on UBI 9.6. May help many of us here.

    yum install -y python3.12 python3.12-devel ncurses gcc gcc-c++ libjpeg-devel gfortran --skip-broken --nobest
    
    python3.12 -m venv venv
    
    source venv/bin/activate
    
    pip install --prefer-binary vllm libprotobuf==4.25.8 openblas --extra-index-url=https://wheels.developerfirst.ibm.com/ppc64le/linux
    
    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/venv/lib64/python3.12/site-packages/libprotobuf/lib64
    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/venv/lib64/python3.12/site-packages/openblas/lib/
    
    vllm --help



    ------------------------------
    Shubham Dayma
    ------------------------------



  • 24.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Tue August 26, 2025 09:14 AM

    @Shubham Dayma that got me farther with openblas but now vllm fails for a version of libjpeg that I don't have:

    ImportError: libjpeg.so.62: cannot open shared object file: No such file or directory



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 25.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Wed August 27, 2025 10:39 PM

    Jack, I may have run into that one as well - that may be a dnf install that you need to do, not sure which jpeg packages specifically off the top.  Also, watch then when you set your LD_LIBRARY_PATH; the example Shubham used is "right" in that you want to make sure you add to what is there, just beware of it growing indefinitely while you are testing.  I also have something else in the words that I was testing today to simplify this, but until I get just a bit more I'm limiting it to a few friends who want to test.  :)  



    ------------------------------
    Gerrit
    ------------------------------



  • 26.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Wed August 27, 2025 11:44 PM

    @Gerrit Huizenga thanks, I've gotten farther but never to the point where vllm actually runs.
    I will eagerly await your next steps. I really want to show LLM workloads running on Power with GPUs, eventually with Spyre.



    ------------------------------
    Jack Woehr
    Senior Consultant
    Seiden Group LLC
    Beulah CO
    3038478442
    ------------------------------



  • 27.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Fri August 29, 2025 06:19 AM

    @Jack Woehr Right now the published package is only for the CPU backend and doesn't support GPUs. I don't think we've ever tried vLLM on Power with GPUs



    ------------------------------
    Manjunath Kumatagi
    ------------------------------



  • 28.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon September 01, 2025 03:24 AM

    @Jack Woehr This is the same we want to showcase with @Mirza Ćutuk, but not the time for it yet...
    @Manjunath Kumatagi Would having access to an AC922 with 4 A100 16 GB be of any help to have support with GPUs on Power? To start, then adding Spyre, then adding AMD GPUs (hopefully we'll get support now that both companies have joined forces, even if for something else).



    ------------------------------
    Lionel Clavien, PhD
    IBM Champion for Power
    CTO & Co-founder
    InnoBoost SA
    Lausanne, Switzerland
    ------------------------------



  • 29.  RE: Unleash the power of AI with optimized Python packages for IBM Power!

    Posted Mon September 01, 2025 02:14 AM

    Did you tried installing libjpeg-devel gfortran? It's mentioned in first line.

    yum install -y python3.12 python3.12-devel ncurses gcc gcc-c++ libjpeg-devel gfortran --skip-broken --nobest

    I performed the exact steps and it worked for me.



    ------------------------------
    Shubham Dayma
    ------------------------------