Skip to content

Repository files navigation

luadseams (dseams)

dseams

built with nix

Lua and Fennel library for the d-SEAMS C++ engine (seams-core).

This repository is a library. require("dseams") in Lua, (require :dseams) in Fennel. The engine CLI is seams in seams-core. Python is pydseams. Neighbour search is linkcell.

local dseams = require("dseams")
local cloud = dseams.read("water.lammpstrj")
print(dseams.chill_plus(cloud, {cutoff = 3.5}))
(local dseams (require :dseams))
(local cloud (dseams.read "water.lammpstrj"))
(print (dseams.chill_plus cloud {:cutoff 3.5}))

dseams.core is the compiled registrations. Helpers stay in Lua, like pydseams helpers stay in Python.

Build:

meson setup bbdir --wrap-mode=nofallback
meson compile -C bbdir
LUA_PATH="$PWD/lua/?.lua;;" LUA_CPATH="$PWD/bbdir/?.so;;" \
  lua example_lua/library/read.lua

Nix flake (meson, require("dseams")):

nix build
nix develop
lua example_lua/library/read.lua

require("yoda") still resolves to dseams.

require("dseams") applies the engine twelve-factor table (SEAMS_CONFIG or ./seams.env, then the environment). Occupancy knobs (LINKCELL_TPP, LINKCELL_BLOCK, SEAMS_RESIDENT, SEAMS_CELL) are getenv at the kernel. The leftover yodaStruct -c conf.yml path is a script descriptor, not that table.

Docs: docs/orgmode/ (ox-rst) and docs/source/ (Shibuya).

License

MIT. Fennel is src/include/external/fennel/LICENSE-fennel. sol2 is src/include/external/sol/LICENSE.txt.

About

Lua and Fennel front end for the d-SEAMS C++ engine

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages