Jij-Inc
ommx
Blog
Docs
Changelog
Blog
Docs
Changelog
Overview
Branches
Benchmarks
Runs
Performance History
Latest Results
openjij: Fix inverted sign in obj function in maximization problems (#600) - When sampling maximization problems with the openjij adapter, the objective function values were being returned negative when they should be positive, and vice versa. - This was due to converting them to minimization problems when generating qubo/hubo, but never converting back before evaluating the results.
main
4 hours ago
Benchmark for direct TSP QUBO generation (#599) Co-authored-by: Claude <noreply@anthropic.com>
main
1 day ago
ruff format
python-tsp-qubo-bench
2 days ago
Support quadratic objective and constraints in MPS format (#597) This PR implements support for parsing and writing quadratic terms in MPS format using the QUADOBJ and QCMATRIX sections as supported by solvers like Gurobi. ## Problem The original MPS format only supported linear objectives and constraints. However, many modern solvers like Gurobi extend the format with QUADOBJ and QCMATRIX sections to represent quadratic terms. OMMX can represent quadratic functions internally but couldn't parse or write these extended MPS sections. ## Solution ### Parsing Support - Added `QuadObj` and `QcMatrix` cursor states to the MPS parser state machine - Extended the `Mps` struct with `quad_obj` and `quad_constraints` fields to store quadratic terms - Implemented `read_quadobj_field()` for parsing QUADOBJ sections - Implemented `read_qcmatrix_field()` for parsing QCMATRIX sections with proper constraint name handling - Updated header parsing to handle `QCMATRIX constraint_name` format ### Writing Support - Modified `write_col_entry()` to extract linear coefficients from both linear and quadratic functions - Updated `write_rhs()` to handle constant terms from quadratic functions - Added `write_quadobj()` to output QUADOBJ sections for quadratic objective terms - Added `write_qcmatrix()` to output QCMATRIX sections for quadratic constraint terms - Removed degree restrictions that previously blocked quadratic functions ### Conversion Logic - Enhanced `convert_objective()` to build `Quadratic` functions from parsed quadratic terms - Updated `convert_constraints()` to handle quadratic constraint terms with proper negation for >= constraints - Modified `convert_inequality()` to construct quadratic functions when quadratic terms are present ## Example Usage ```rust // Parse MPS with quadratic terms let mps_content = r#" NAME QUADRATIC_DEMO ROWS N OBJ L CON1 COLUMNS X1 OBJ 1 X2 OBJ 2 RHS RHS1 CON1 10 QUADOBJ X1 X1 0.5 X1 X2 1.0 QCMATRIX CON1 X1 X2 0.25 ENDATA "#; let instance = ommx::mps::parse(mps_content.as_bytes())?; assert_eq!(instance.objective().degree(), 2); // Quadratic objective ``` ## Testing Added comprehensive tests covering: - `test_parse_quadobj` - Parsing QUADOBJ sections - `test_parse_qcmatrix` - Parsing QCMATRIX sections - `test_parse_combined_quadratic` - Both sections together - `test_quadratic_mps_roundtrip` - Full roundtrip (parse ā write ā parse) - Updated existing error tests to verify cubic functions (degree 3) still fail appropriately All 30 MPS tests pass, maintaining full backward compatibility with existing linear MPS files. Fixes #596. > [!WARNING] > > <details> > <summary>Firewall rules blocked me from connecting to one or more addresses</summary> > > #### I tried to connect to the following addresses, but was blocked by firewall rules: > > - `taskfile.dev` > - Triggering command: `curl -sL REDACTED` (dns block) > > If you need me to access, download, or install something from one of these locations, you can either: > > - Configure [Actions setup steps](https://gh.io/copilot/actions-setup-steps) to set up my environment, which run before the firewall is enabled > - Add the appropriate URLs or hosts to the custom allowlist in this repository's [Copilot coding agent settings](https://github.com/Jij-Inc/ommx/settings/copilot/coding_agent) (admins only) > > </details> <!-- START COPILOT CODING AGENT TIPS --> --- š” You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more [Copilot coding agent tips](https://gh.io/copilot-coding-agent-tips) in the docs. --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: termoshtt <1238153+termoshtt@users.noreply.github.com> Co-authored-by: Toshiki Teramura <toshiki.teramura@gmail.com> Co-authored-by: Claude <noreply@anthropic.com>
main
2 days ago
Start developing OMMX Python SDK 2.0.5 (#594) Automated changes by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action Co-authored-by: termoshtt <1238153+termoshtt@users.noreply.github.com>
main
6 days ago
Upgrade uv.lock (#592)
main
7 days ago
Add explicit permissions to GitHub Actions workflows (#590) Following the principle of least privilege, add explicit permissions blocks to all workflows: - Read-only permissions for workflows that only need to checkout and test code - Write permissions only where necessary (creating PRs, publishing releases) This addresses security warnings about workflows without explicit permissions limits. š¤ Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>
main
7 days ago
Setup grouping for uv dependabot updates (#588)
main
7 days ago
Active Branches
No pull requests found
As pull requests are created, their performance will appear here.
Ā© 2025 CodSpeed Technology
Home
Terms
Privacy
Docs