Skip to content

New reduction rule: BinaryMatrixFactorization to BicliqueCover #140

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

c-allergic
Copy link
Collaborator

Problems: findbest method could not be applied to BicliqueCover yet due to the specific configuration shape of BicliqueCover. Therefore, the extract_solution function and the reduction correctness are not yet tested.

Copy link

codecov bot commented Mar 26, 2025

Codecov Report

Attention: Patch coverage is 98.14815% with 1 line in your changes missing coverage. Please review.

Project coverage is 93.84%. Comparing base (cd69262) to head (9e23fb0).
Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
src/models/BicliqueCover.jl 94.44% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #140      +/-   ##
==========================================
+ Coverage   93.26%   93.84%   +0.58%     
==========================================
  Files          38       39       +1     
  Lines        1588     1642      +54     
==========================================
+ Hits         1481     1541      +60     
+ Misses        107      101       -6     

☔ 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.

Base.:(==)(a::ReductionBMFToBicliqueCover, b::ReductionBMFToBicliqueCover) = a.bicliquecover == b.bicliquecover && a.k == b.k
target_problem(res::ReductionBMFToBicliqueCover) = res.bicliquecover

function reduceto(::Type{BicliqueCover}, bmf::BinaryMatrixFactorization)
Copy link
Owner

Choose a reason for hiding this comment

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

Suggested change
function reduceto(::Type{BicliqueCover}, bmf::BinaryMatrixFactorization)
function reduceto(::Type{<:BicliqueCover}, bmf::BinaryMatrixFactorization)

return (B,C)
end

function extract_multiple_solutions(res::ReductionBMFToBicliqueCover{Int64}, solution_set::Vector{Vector{Vector{Int64}}})
Copy link
Owner

Choose a reason for hiding this comment

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

We do not need this?

end
end
end
return (B,C)
Copy link
Owner

Choose a reason for hiding this comment

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

Should return a vector, and convert it back with read_solution. e.g.

function read_solution(factoring::Factoring,solution::AbstractVector) #return a tuple of 2 numbers result

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.

2 participants