Skip to content

Hipo python docs#3024

Open
galabovaa wants to merge 5 commits into
latestfrom
hipo-python-docs
Open

Hipo python docs#3024
galabovaa wants to merge 5 commits into
latestfrom
hipo-python-docs

Conversation

@galabovaa
Copy link
Copy Markdown
Contributor

No description provided.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.81%. Comparing base (97e2caa) to head (f53f1eb).
⚠️ Report is 1 commits behind head on latest.

Additional details and impacted files
@@           Coverage Diff           @@
##           latest    #3024   +/-   ##
=======================================
  Coverage   72.80%   72.81%           
=======================================
  Files         417      417           
  Lines      102150   102150           
  Branches    16464    16463    -1     
=======================================
+ Hits        74372    74376    +4     
+ Misses      27502    27498    -4     
  Partials      276      276           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@@ -0,0 +1,69 @@
# [HiPO in Python](@id hipo-in-python)

The HiPO Interior Point Method (IPM) solver currently uses external dependencies to provide enhanced performance for linear and quadratic programming problems. The required dependencies are packaged in the `highspy-extras`. The packaged dependencies have licensing terms different from HiGHS, such as Apache 2.0. Other algorithms may also rely on `highspy_extras` in the future.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose highspy_extras should be highspy-extras

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, this is a good point - and is actually a slightly larger issue that's been on my mind.

If we're going to standardize, we probably should choose highspy_extras instead of highspy-extras, since import highspy-extras will give a syntax error.

Python actually treats - and _ in package names as equivalent, that is, it's valid to use pip install highspy-extras and then import highspy_extras. However, users should never have to manually import this package themselves.

Choosing highspy_extras is also consistent with the associated highs_extras library. That said, highspy-extras looks better to me as a package name (I don't know why).

Options:

  1. keep highspy-extras and refer to it everywhere as highspy-extras (except in advanced examples involving import)
  2. rename to highspy_extras for consistency
  3. rename to highspyextras and avoid the whole - and _ weirdness.

I don't really have a strong preference, though, I'm leaning towards option 1. Thoughts @galabovaa?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

However, users should never have to manually import this package themselves.

Is this worth mentioning explicitly in the documentation? I'm not a Python person, so I don't know how likely users are to try importing it, receiving a syntax error.

Copy link
Copy Markdown
Collaborator

@mathgeekcoder mathgeekcoder May 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It certainly wouldn't hurt to explicitly mention. Possibly under ## Usage?? e.g.,

Usage

When highspy-extras is installed, HiGHS can use algorithms that depend on these external libraries. At present this primarily means the HiPO solver. Note that highspy-extras is automatically consumed by highspy and does not need to be imported manually. You can explicitly select HiPO:

or

When highspy-extras is installed, HiGHS can enable algorithms that rely on these external libraries, such as the HiPO solver. highspy-extras is automatically detected and used by highspy, so no explicit import is required. You can select HiPO:

or something to that effect


## Usage

When `highspy_extras` is installed, HiGHS can use algorithms that depend on these external libraries. At present this primarily means the HiPO solver. You can explicitly select HiPO:
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose highspy_extras should be highspy-extras

Comment thread README.md
To use HiPO in Python, the additional `highspy-extras` is required. It contains the HiPO dependencies and is Apache 2.0 licensed. It can be installed with

```shell
$ pip install highspy[hipo]
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose highspy[hipo] should be highspy[extras]

Copy link
Copy Markdown
Member

@jajhall jajhall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that @filikat has identified the typos, this looks good to me!

Copy link
Copy Markdown
Collaborator

@mathgeekcoder mathgeekcoder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Just want to clarify our highspy-extras vs highspy_extras decision.

@@ -0,0 +1,69 @@
# [HiPO in Python](@id hipo-in-python)

The HiPO Interior Point Method (IPM) solver currently uses external dependencies to provide enhanced performance for linear and quadratic programming problems. The required dependencies are packaged in the `highspy-extras`. The packaged dependencies have licensing terms different from HiGHS, such as Apache 2.0. Other algorithms may also rely on `highspy_extras` in the future.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, this is a good point - and is actually a slightly larger issue that's been on my mind.

If we're going to standardize, we probably should choose highspy_extras instead of highspy-extras, since import highspy-extras will give a syntax error.

Python actually treats - and _ in package names as equivalent, that is, it's valid to use pip install highspy-extras and then import highspy_extras. However, users should never have to manually import this package themselves.

Choosing highspy_extras is also consistent with the associated highs_extras library. That said, highspy-extras looks better to me as a package name (I don't know why).

Options:

  1. keep highspy-extras and refer to it everywhere as highspy-extras (except in advanced examples involving import)
  2. rename to highspy_extras for consistency
  3. rename to highspyextras and avoid the whole - and _ weirdness.

I don't really have a strong preference, though, I'm leaning towards option 1. Thoughts @galabovaa?

To install locally, you will need

- Python >= 3.8
- BLAS library (bundled or system)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to clarify, for BLAS, the system requirement is only for Apple right? Since we're bundling OpenBLAS.

It is technically correct as written, but users might think they need to install additional libraries.

@galabovaa
Copy link
Copy Markdown
Contributor Author

Thank you for your comments!

@mathgeekcoder, I agree that

  1. keep highspy-extras and refer to it everywhere as highspy-extras (except in advanced examples involving import)

for some reason, seems most visually pleasing. I will make the corresponding updates.

I did not realize that for python it does not matter. I guess I assumed that there was a reason we were using both, like the highspy_extras being a small wrapper over the C++ lib and the highspy-extras being the python package, but that seems to not be the case 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants