Add fallback for Bool verbose, and two-arg SciMLMessage Macro#38
Merged
ChrisRackauckas merged 3 commits intoSciML:mainfrom Nov 8, 2025
Merged
Add fallback for Bool verbose, and two-arg SciMLMessage Macro#38ChrisRackauckas merged 3 commits intoSciML:mainfrom
Bool verbose, and two-arg SciMLMessage Macro#38ChrisRackauckas merged 3 commits intoSciML:mainfrom
Conversation
Member
Author
|
@ChrisRackauckas this would fix downstream tests for SciML/OrdinaryDiffEq.jl#2895 and also adds a (maybe not very useful) way to use the SciMLMessage macro. I've tested it locally with current versions of LinearSolve and NonlinearSolve and the branch of OrdinaryDiffEq in that PR to make sure that no overhead was introduced, and that the SciMLLogging code is able to be compiled out. Also made sure JET test_opt still works for LinearSolve. using LinearSolve
A = [1.0 0 0 0
0 1 0 0
0 0 1 0
0 0 0 0]
b = rand(4)
prob = LinearProblem(A, b)
@test_opt solve(prob, LUFactorization(), verbose = SciMLLogging.None())
Test Passed
(Demo) pkg> st
Status `~/Documents/Work/dev/VerbosityDemo/Demo/Project.toml`
[7ed4a6bd] LinearSolve v3.46.1
[e6f89c97] LoggingExtras v1.2.0
[8913a72c] NonlinearSolve v4.12.0
[1dea7af3] OrdinaryDiffEq v6.103.0 `~/Documents/Work/dev/OrdinaryDiffEq.jl`
[6ad6398a] OrdinaryDiffEqBDF v1.11.0 `~/Documents/Work/dev/OrdinaryDiffEq.jl/lib/OrdinaryDiffEqBDF`
[bbf590c4] OrdinaryDiffEqCore v1.37.0 `~/Documents/Work/dev/OrdinaryDiffEq.jl/lib/OrdinaryDiffEqCore`
[127b3ac7] OrdinaryDiffEqNonlinearSolve v1.16.0 `~/Documents/Work/dev/OrdinaryDiffEq.jl/lib/OrdinaryDiffEqNonlinearSolve`
[a6db7da4] SciMLLogging v1.4.0 `~/Documents/Work/dev/SciMLLogging.jl`
[4536629a] OpenBLAS_jll v0.3.29+0
|
ChrisRackauckas
approved these changes
Nov 8, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checklist
contributor guidelines, in particular the SciML Style Guide and
COLPRAC.
Additional context
Adds a fallback for when a verbose is Bool. Also adds a two-argument SciMLMessage macro that takes a Bool, if verb is true emit a warning with the message.