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
const USE_GPU = true | |
using ParallelStencil | |
using ParallelStencil.FiniteDifferences3D | |
@static if USE_GPU | |
@init_parallel_stencil(CUDA, Float64, 3) | |
else | |
@init_parallel_stencil(Threads, Float64, 3) | |
end | |
using ImplicitGlobalGrid, Plots, Printf, Statistics, LinearAlgebra # ATTENTION: plotting fails inside plotting library if using flag '--math-mode=fast'. | |
import MPI |
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
const USE_GPU = false # Use GPU? If this is set false, then no GPU needs to be available | |
using ParallelStencil | |
using ParallelStencil.FiniteDifferences2D | |
@static if USE_GPU | |
@init_parallel_stencil(CUDA, Float64, 2) | |
else | |
@init_parallel_stencil(Threads, Float64, 2) | |
end | |
using Plots, Printf, Statistics |
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
using ParallelStencil | |
using ParallelStencil.FiniteDifferences2D | |
using Plots, Printf, Statistics, LinearAlgebra | |
@parallel function assign!(A::Data.Array, B::Data.Array) | |
@all(A) = @all(B) | |
return | |
end | |
@parallel function compute_error!(Err_A::Data.Array, A::Data.Array) |
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
const USE_GPU = false # Use GPU? If this is set false, then no GPU needs to be available | |
using ParallelStencil | |
using ParallelStencil.FiniteDifferences2D | |
@static if USE_GPU | |
@init_parallel_stencil(CUDA, Float64, 2) | |
else | |
@init_parallel_stencil(Threads, Float64, 2) | |
end | |
using Plots, Printf, Statistics |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
### A Pluto.jl notebook ### | |
# v0.18.4 | |
using Markdown | |
using InteractiveUtils | |
# ╔═╡ 17d3ca02-afa8-11ec-2f02-21d36cc79349 | |
using Distributed, ClusterManagers | |
# ╔═╡ eda32dec-9254-4a77-bfe2-2bdb63128fd0 |
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
apiVersion: kubevirt.io/v1 | |
kind: VirtualMachineInstance | |
metadata: | |
name: vm1 | |
labels: | |
vmi : vm1 | |
spec: | |
terminationGracePeriodSeconds: 30 | |
domain: | |
resources: |
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
@everywhere begin | |
using NeuralPDE, Flux, ModelingToolkit, GalacticOptim, Optim, DiffEqFlux | |
import ModelingToolkit: Interval, infimum, supremum | |
end | |
@everywhere begin | |
@parameters t, x | |
@variables u(..) | |
Dxx = Differential(x)^2 | |
Dtt = Differential(t)^2 |
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
@everywhere begin | |
using NeuralPDE, Flux, ModelingToolkit, GalacticOptim, Optim, DiffEqFlux | |
import ModelingToolkit: Interval, infimum, supremum | |
end | |
# the example is taken from this article https://arxiv.org/abs/1910.10503 | |
@everywhere begin | |
@parameters x | |
@variables p(..) | |
Dx = Differential(x) |
NewerOlder