Skip to content

Commit 0950d29

Browse files
ytdHuangalbertomercurio
authored andcommitted
format files
1 parent bdd9871 commit 0950d29

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

src/time_evolution/smesolve.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -250,8 +250,8 @@ function smesolveEnsembleProblem(
250250
store_measurement = makeVal(store_measurement),
251251
) : prob_func
252252
_output_func =
253-
output_func isa Nothing ?
254-
_ensemble_dispatch_output_func(ensemblealg, progress_bar, ntraj, _dummy_output_func) : output_func
253+
output_func isa Nothing ? _ensemble_dispatch_output_func(ensemblealg, progress_bar, ntraj, _dummy_output_func) :
254+
output_func
255255

256256
prob_sme = smesolveProblem(
257257
H,

src/time_evolution/ssesolve.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -244,8 +244,8 @@ function ssesolveEnsembleProblem(
244244
store_measurement = makeVal(store_measurement),
245245
) : prob_func
246246
_output_func =
247-
output_func isa Nothing ?
248-
_ensemble_dispatch_output_func(ensemblealg, progress_bar, ntraj, _dummy_output_func) : output_func
247+
output_func isa Nothing ? _ensemble_dispatch_output_func(ensemblealg, progress_bar, ntraj, _dummy_output_func) :
248+
output_func
249249

250250
prob_sme = ssesolveProblem(
251251
H,

src/time_evolution/time_evolution.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -357,9 +357,6 @@ Helpers for handling output of ensemble problems.
357357
This is very useful especially for dispatching which method to use to update the progress bar.
358358
=#
359359

360-
# a dummy output function which does nothing
361-
_dummy_output_func(sol, i) = (sol, false)
362-
363360
# Output function with progress bar update
364361
function _ensemble_output_func_progress(sol, i, progr, output_func)
365362
next!(progr)
@@ -455,6 +452,9 @@ function _stochastic_prob_func(prob, i, repeat, rng, seeds, tlist; kwargs...)
455452
return remake(prob.prob, noise = noise, seed = seed)
456453
end
457454

455+
# a dummy output function which does nothing (used for mapped and stochastic solvers)
456+
_dummy_output_func(sol, i) = (sol, false)
457+
458458
#=
459459
Define diagonal or non-diagonal noise depending on the type of `sc_ops`.
460460
If `sc_ops` is a `AbstractQuantumObject`, we avoid using the non-diagonal noise.

0 commit comments

Comments
 (0)