11
11
12
12
# Linear Verbosity
13
13
14
- # linear_defaults = Dict(
15
- # :default_lu_fallback => Verbosity.Warn()
16
- # :no_right_preconditioning => Verbosity.Warn()
17
- # :using_iterative_solvers => Verbosity.Warn()
18
- # :using_IterativeSolvers => Verbosity.Warn()
19
- # :IterativeSolvers_iterations => Verbosity.Warn()
20
- # :KrylovKit_verbosity => Verbosity.Warn()
21
- # )
14
+ linear_defaults = Dict (
15
+ :default_lu_fallback => Verbosity. Warn (),
16
+ :no_right_preconditioning => Verbosity. Warn (),
17
+ :using_iterative_solvers => Verbosity. Warn (),
18
+ :using_IterativeSolvers => Verbosity. Warn (),
19
+ :IterativeSolvers_iterations => Verbosity. Warn (),
20
+ :KrylovKit_verbosity => Verbosity. Warn ()
21
+ )
22
22
mutable struct LinearErrorControlVerbosity
23
23
default_lu_fallback:: Verbosity.Type
24
24
25
25
function LinearErrorControlVerbosity (;
26
26
default_lu_fallback = linear_defaults[:default_lu_fallback ])
27
27
new (default_lu_fallback)
28
28
end
29
- end
30
29
31
- function LinearErrorControlVerbosity (verbose:: Verbosity.Type )
32
- @match verbose begin
33
- Verbosity. None () => LinearErrorControlVerbosity (fill (
34
- Verbosity. None (), length (fieldnames (LinearErrorControlVerbosity)))... )
30
+ function LinearErrorControlVerbosity (verbose:: Verbosity.Type )
31
+ @match verbose begin
32
+ Verbosity. None () => new (fill (
33
+ Verbosity. None (), length (fieldnames (LinearErrorControlVerbosity)))... )
35
34
36
- Verbosity. Info () => LinearErrorControlVerbosity (fill (
37
- Verbosity. Info (), length (fieldnames (LinearErrorControlVerbosity)))... )
35
+ Verbosity. Info () => new (fill (
36
+ Verbosity. Info (), length (fieldnames (LinearErrorControlVerbosity)))... )
38
37
39
- Verbosity. Warn () => LinearErrorControlVerbosity (fill (
40
- Verbosity. Warn (), length (fieldnames (LinearErrorControlVerbosity)))... )
38
+ Verbosity. Warn () => new (fill (
39
+ Verbosity. Warn (), length (fieldnames (LinearErrorControlVerbosity)))... )
41
40
42
- Verbosity. Error () => LinearErrorControlVerbosity (fill (
43
- Verbosity. Error (), length (fieldnames (LinearErrorControlVerbosity)))... )
41
+ Verbosity. Error () => new (fill (
42
+ Verbosity. Error (), length (fieldnames (LinearErrorControlVerbosity)))... )
44
43
45
- Verbosity. Default () => LinearErrorControlVerbosity ()
44
+ Verbosity. Default () => LinearErrorControlVerbosity ()
46
45
47
- Verbosity. Edge () => LinearErrorControlVerbosity ()
46
+ Verbosity. Edge () => LinearErrorControlVerbosity ()
48
47
49
- _ => @error " Not a valid choice for verbosity."
48
+ _ => @error " Not a valid choice for verbosity."
49
+ end
50
50
end
51
51
end
52
52
53
+
53
54
mutable struct LinearPerformanceVerbosity
54
55
no_right_preconditioning:: Verbosity.Type
56
+
55
57
function LinearPerformanceVerbosity (;
56
58
no_right_preconditioning = linear_defaults[:no_right_preconditioning ])
57
59
new (no_right_preconditioning)
58
60
end
59
- end
60
61
61
- function LinearPerformanceVerbosity (verbose:: Verbosity.Type )
62
- @match verbose begin
63
- Verbosity. None () => LinearPerformanceVerbosity (fill (
64
- Verbosity. None (), length (fieldnames (LinearPerformanceVerbosity)))... )
62
+ function LinearPerformanceVerbosity (verbose:: Verbosity.Type )
63
+ @match verbose begin
64
+ Verbosity. None () => new (fill (
65
+ Verbosity. None (), length (fieldnames (LinearPerformanceVerbosity)))... )
65
66
66
- Verbosity. Info () => LinearPerformanceVerbosity (fill (
67
- Verbosity. Info (), length (fieldnames (LinearPerformanceVerbosity)))... )
67
+ Verbosity. Info () => new (fill (
68
+ Verbosity. Info (), length (fieldnames (LinearPerformanceVerbosity)))... )
68
69
69
- Verbosity. Warn () => LinearPerformanceVerbosity (fill (
70
- Verbosity. Warn (), length (fieldnames (LinearPerformanceVerbosity)))... )
70
+ Verbosity. Warn () => new (fill (
71
+ Verbosity. Warn (), length (fieldnames (LinearPerformanceVerbosity)))... )
71
72
72
- Verbosity. Error () => LinearPerformanceVerbosity (fill (
73
- Verbosity. Error (), length (fieldnames (LinearPerformanceVerbosity)))... )
73
+ Verbosity. Error () => new (fill (
74
+ Verbosity. Error (), length (fieldnames (LinearPerformanceVerbosity)))... )
74
75
75
- Verbosity. Default () => LinearPerformanceVerbosity ()
76
+ Verbosity. Default () => LinearPerformanceVerbosity ()
76
77
77
- Verbosity. Edge () => LinearPerformanceVerbosity ()
78
+ Verbosity. Edge () => LinearPerformanceVerbosity ()
78
79
79
- _ => @error " Not a valid choice for verbosity."
80
+ _ => @error " Not a valid choice for verbosity."
81
+ end
80
82
end
83
+
81
84
end
82
85
83
86
mutable struct LinearNumericalVerbosity
@@ -91,30 +94,32 @@ mutable struct LinearNumericalVerbosity
91
94
KrylovKit_verbosity = linear_defaults[:KrylovKit_verbosity ])
92
95
new (using_IterativeSolvers, IterativeSolvers_iterations, KrylovKit_verbosity)
93
96
end
94
- end
95
97
96
- function LinearNumericalVerbosity (verbose:: Verbosity.Type )
97
- @match verbose begin
98
- Verbosity. None () => LinearNumericalVerbosity (fill (
99
- Verbosity. None (), length (fieldnames (LinearNumericalVerbosity)))... )
98
+ function LinearNumericalVerbosity (verbose:: Verbosity.Type )
99
+ @match verbose begin
100
+ Verbosity. None () => new (fill (
101
+ Verbosity. None (), length (fieldnames (LinearNumericalVerbosity)))... )
100
102
101
- Verbosity. Info () => LinearNumericalVerbosity (fill (
102
- Verbosity. Info (), length (fieldnames (LinearNumericalVerbosity)))... )
103
+ Verbosity. Info () => new (fill (
104
+ Verbosity. Info (), length (fieldnames (LinearNumericalVerbosity)))... )
103
105
104
- Verbosity. Warn () => LinearNumericalVerbosity (fill (
105
- Verbosity. Warn (), length (fieldnames (LinearNumericalVerbosity)))... )
106
+ Verbosity. Warn () => new (fill (
107
+ Verbosity. Warn (), length (fieldnames (LinearNumericalVerbosity)))... )
106
108
107
- Verbosity. Error () => LinearNumericalVerbosity (fill (
108
- Verbosity. Error (), length (fieldnames (LinearNumericalVerbosity)))... )
109
+ Verbosity. Error () => new (fill (
110
+ Verbosity. Error (), length (fieldnames (LinearNumericalVerbosity)))... )
109
111
110
- Verbosity. Default () => LinearNumericalVerbosity ()
112
+ Verbosity. Default () => LinearNumericalVerbosity ()
111
113
112
- Verbosity. Edge () => LinearNumericalVerbosity ()
114
+ Verbosity. Edge () => LinearNumericalVerbosity ()
113
115
114
- _ => @error " Not a valid choice for verbosity."
116
+ _ => @error " Not a valid choice for verbosity."
117
+ end
115
118
end
116
119
end
117
120
121
+
122
+
118
123
struct LinearVerbosity{T} <: AbstractVerbositySpecifier{T}
119
124
error_control:: LinearErrorControlVerbosity
120
125
performance:: LinearPerformanceVerbosity
0 commit comments