comparison: src/Util.jl
src/Util.jl
- changeset 18
- 0253c5881812
- parent 10
- e9edf00242a3
- child 19
- 63849571a046
equal
deleted
inserted
replaced
20 norm₂₁, |
20 norm₂₁, |
21 γnorm₂₁, |
21 γnorm₂₁, |
22 dot, |
22 dot, |
23 mean, |
23 mean, |
24 proj_norm₂₁ball!, |
24 proj_norm₂₁ball!, |
|
25 proj_nonneg!, |
25 curry, |
26 curry, |
26 ⬿, |
27 ⬿, |
27 @threadsif, |
28 @threadsif, |
28 @background, |
29 @background, |
29 @backgroundif |
30 @backgroundif |
189 end |
190 end |
190 end |
191 end |
191 end |
192 end |
192 end |
193 end |
193 |
194 |
|
195 @inline function proj_nonneg!(y) |
|
196 @inbounds @simd for i=1:length(y) |
|
197 if y[i] < 0 |
|
198 y[i] = 0 |
|
199 end |
|
200 end |
|
201 return y |
|
202 end |
|
203 |
194 end # Module |
204 end # Module |
195 |
205 |