Hypermesh Python API: Get Multiple Entities

KrisGarner
KrisGarner Altair Community Member
edited May 2024 in Community Q&A

Hi. Just wondering if there is a Python API (i.e. method) to get multiple entities?  The "get" class method (for the Session object) can get a single entity, but what I want to do is get multiple entities (CurveXY entities in my case), put them in a Python list (say), do some maths on them, and then write out either multiple or single curves.

If this not available in 2023.1, is there a plan to implement this in a future version?

Thanks,

Kristian

Answers

  • Michal Stefuca
    Michal Stefuca
    Altair Employee
    edited May 2024

    Hi Kristian,

    At the moment, we do no support a collection mechanism for HyperGraph entities, but it is part of our roadmap. We are planning to start the work on it when the currently running HyperGraph Python API projects are closed.

    Thanks,

    Michal Stefuca
    Automation & Customization

  • KrisGarner
    KrisGarner Altair Community Member

    Hi Michal,

    Thanks for your comment. We are starting to look at this again in 2024.1 and wondering if you have any updates on when this might be implemented? The get method can be used for many different single entity types, so having a complementary method to get multiple entities would be very useful in many applications. For my own application, I want to get all curves in the current window and then filter (e.g. by subcase) and then do some curve maths on them (e.g. add them all up and do a max envelope of the lot). At the moment, the only way round this I can see is to write my own (slightly hacky) modules/functions, but it would be nice to have these in the core code.

    Thanks,

    Kristian

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.