From 4ecdd1d07103cfea44fb569bbc1505071a9371e3 Mon Sep 17 00:00:00 2001 From: Sikorski Date: Tue, 10 Sep 2024 13:45:20 +0200 Subject: [PATCH] fixed typos --- scripts/atefe.jl | 2 +- src/ISOKANN.jl | 2 ++ src/simulators/openmm.jl | 4 ++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/atefe.jl b/scripts/atefe.jl index 406ea3d..c041a81 100644 --- a/scripts/atefe.jl +++ b/scripts/atefe.jl @@ -4,7 +4,7 @@ using CUDA end -@time "loading" sim = OpenMMScript("data/atefe/mor.py", steps=10_000) +@time "loading" sim = OpenMMSimulation(py="data/atefe/mor.py", steps=10_000) NFEATURES = 3000 NX = 1_000 diff --git a/src/ISOKANN.jl b/src/ISOKANN.jl index f4043b5..688f276 100644 --- a/src/ISOKANN.jl +++ b/src/ISOKANN.jl @@ -53,6 +53,8 @@ import LinearAlgebra import MLUtils: numobs import Flux: cpu, gpu +export OpenMM + export pairnet #export PDB_ACEMD, PDB_1UAO, PDB_diala_water #export MollyLangevin, propagate, solve#, MollySDE diff --git a/src/simulators/openmm.jl b/src/simulators/openmm.jl index 58bc86b..3b6fc18 100644 --- a/src/simulators/openmm.jl +++ b/src/simulators/openmm.jl @@ -108,7 +108,7 @@ end mmthreads(sim::OpenMMSimulation) = get(sim.constructor, :mmthreads, CUDA.has_cuda() ? "gpu" : 1) nthreads(sim::OpenMMSimulation) = get(sim.constructor, :nthreads, CUDA.has_cuda() ? 1 : Threads.nthreads()) momenta(sim::OpenMMSimulation) = get(sim.constructor, :momenta, false) -pdbfile(sim::OpenMMSimulation) = get(sim.constructor, :pdb, () -> createpdb(sim)) +pdbfile(sim::OpenMMSimulation) = get(() -> createpdb(sim), sim.constructor, :pdb) steps(sim) = sim.steps::Int friction(sim) = friction(sim.pysim) @@ -133,7 +133,7 @@ function createpdb(sim) pysim = sim.pysim file = tempname() * ".pdb" pdb = py"app.PDBFile" - pdb.writeFile(pysim.topology, pysim.positions, file) # TODO: fix this + pdb.writeFile(pysim.topology, PyReverseDims(reshape(getcoords(sim), 3, :)), file) # TODO: fix this return file end