Skip to content

Commit

Permalink
Fixed MPI Issue
Browse files Browse the repository at this point in the history
  • Loading branch information
JTHesse committed Mar 19, 2024
1 parent 08b4d56 commit 799ce14
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 5 deletions.
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,16 @@ SPDX-License-Identifier: BSD-3-Clause

All notable changes to this project will be documented in this file.

## [1.1.0] - 2024-
## [1.1.0] - 2024-03-19

### Added
### Changed

- Julia version

### Fixed

- MPI Issue
- Logging


## [1.0.7] - 2024-03-12
Expand Down
6 changes: 5 additions & 1 deletion src/PeriLab.jl
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ function main()::Cint
end
MPI.Init()
main(parsed_args["filename"], parsed_args["output_dir"], parsed_args["dry_run"], parsed_args["verbose"], parsed_args["debug"], parsed_args["silent"])
MPI.Finalize()
return 0
end

Expand Down Expand Up @@ -190,6 +189,10 @@ This function serves as the entry point for the PeriLab application. It calls th
function main(filename::String, output_dir::String="", dry_run::Bool=false, verbose::Bool=false, debug::Bool=false, silent::Bool=false)

@timeit to "PeriLab" begin
if !MPI.Initialized()
MPI.Init()
end
@info "Bla"
comm = MPI.COMM_WORLD
rank = MPI.Comm_rank(comm)
size = MPI.Comm_size(comm)
Expand Down Expand Up @@ -271,6 +274,7 @@ function main(filename::String, output_dir::String="", dry_run::Bool=false, verb
TimerOutputs.complement!(to)
@info to
end
MPI.Finalize()
end

end # module
3 changes: 1 addition & 2 deletions src/main.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,4 @@ end

MPI.Init()
import PeriLab
PeriLab.main()
MPI.Finalize()
PeriLab.main()

0 comments on commit 799ce14

Please sign in to comment.