mechsys
Use when a task mentions MechSys, tdem, tlbmdem, DEM/Particle/Voronoi optimization, CUDA DEM tests, LBM-DEM, or the MechSys simulation library in this workspace.
한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.
실행 점수 미검증
설치 방법 보기포함된 파일(200)
- SKILL.md5.0 KB
- .agents/skills/mechsys/SKILL.md5.0 KB
- .gitignore2.3 KB
- AGENTS.md9.2 KB
- authors.txt22 B
- CMakeLists.txt22.8 KB
- debian/changelog1.5 KB
- debian/compat2 B
- debian/control1.4 KB
- debian/copyright1.4 KB
- debian/rules909 B
- lib/adlbm/Cell.h9.9 KB
- lib/adlbm/Domain.h14.0 KB
- lib/adlbm/Lattice.h6.9 KB
- lib/datfiles.h13.0 KB
- lib/dem.h1.9 KB
- lib/dem/basic_functions.h3.3 KB
- lib/dem/cylinder.h3.0 KB
- lib/dem/dem.cuh39.0 KB
- lib/dem/distance.h27.7 KB
- lib/dem/domain.h163.6 KB
- lib/dem/dompargen.h49.2 KB
- lib/dem/edge.h2.2 KB
- lib/dem/face.h5.6 KB
- lib/dem/graph.h4.2 KB
- lib/dem/gsd.h60.0 KB
- lib/dem/interacton.h47.2 KB
- lib/dem/particle.h49.9 KB
- lib/dem/special_functions.h18.5 KB
- lib/dem/torus.h2.3 KB
- lib/dem/visualise.h11.8 KB
- lib/dfn/Domain.h91.6 KB
- lib/dfn/Fracture.h9.7 KB
- lib/dfn/Graph_x.h3.2 KB
- lib/dfn/Line.h960 B
- lib/dfn/Loop.h11.9 KB
- lib/dfn/Math.h15.4 KB
- lib/dfn/Random_function.h10.3 KB
- lib/doxymain.h10.1 KB
- lib/draw.h3.1 KB
- lib/emlbm/Cell.h8.2 KB
- lib/emlbm/Domain.h20.9 KB
- lib/emlbm/Lattice.h6.4 KB
- lib/emlbm2/Cell.h8.0 KB
- lib/emlbm2/Domain.h14.4 KB
- lib/emlbm2/Lattice.h4.5 KB
- lib/flbm/Domain.h101.6 KB
- lib/flbm/lbm.cl17.6 KB
- lib/flbm/lbm.cuh49.5 KB
- lib/geomtype.h2.9 KB
- lib/inpfile.h51.4 KB
- lib/lbm/Cell.h12.2 KB
- lib/lbm/Dem.h5.3 KB
- lib/lbm/Domain.h170.5 KB
- lib/lbm/Dompargen.h39.3 KB
- lib/lbm/Interacton.h5.3 KB
- lib/lbm/Lattice.h20.4 KB
- lib/lbmdem/Domain.h50.0 KB
- lib/lbmdem/lbmdem.cuh40.7 KB
- lib/lbmmpm/Domain.h22.9 KB
- lib/linalg/jacobirot.h7.1 KB
- lib/linalg/laexpr.h43.2 KB
- lib/linalg/matrix.h13.4 KB
- lib/linalg/matvec.h89.9 KB
- lib/linalg/mumps.h4.1 KB
- lib/linalg/quaternion.h5.3 KB
- lib/linalg/sparse_crmatrix.h15.5 KB
- lib/linalg/sparse_matrix.h18.5 KB
- lib/linalg/sparse_triplet.h14.0 KB
- lib/linalg/superlu.h3.9 KB
- lib/linalg/superlud.h6.6 KB
- lib/linalg/umfpack.h7.9 KB
- lib/linalg/vector.h11.6 KB
- lib/matfile.h17.5 KB
- lib/mesh/alphashape.h5.6 KB
- lib/mesh/delaunay.h5.4 KB
- lib/mesh/mesh.h79.8 KB
- lib/mesh/paragrid3d.h14.2 KB
- lib/mesh/structured.h51.4 KB
- lib/mesh/unstructured.h49.3 KB
- lib/mpm/Corner.h3.5 KB
- lib/mpm/Domain.h76.8 KB
- lib/mpm/mpm.cuh5.6 KB
- lib/mpm/Node.h7.8 KB
- lib/mpm/Particle.h11.8 KB
- lib/mpm/shape_functions.h3.8 KB
- lib/nn/Domain.h22.2 KB
- lib/numerical/min.h9.8 KB
- lib/numerical/montecarlo.h4.9 KB
- lib/numerical/multipleroots.h6.5 KB
- lib/numerical/numdiff.h3.6 KB
- lib/numerical/odesolver.h12.1 KB
- lib/numerical/quadrature.h9.1 KB
- lib/numerical/root.h9.1 KB
- lib/python/msys_ana.py3.0 KB
- lib/python/msys_drawmesh.py30.6 KB
- lib/python/msys_fcrits.py21.7 KB
- lib/python/msys_fig.py16.2 KB
- lib/python/msys_invs.py17.2 KB
- lib/python/msys_linfit.py3.9 KB
- lib/python/msys_matvec.py4.4 KB
- lib/python/msys_plt.py19.3 KB
- lib/python/msys_pyshell.py8.8 KB
- lib/sph/Boundary_Condition.h2.8 KB
- lib/sph/Domain.h129.3 KB
- lib/sph/Dompargen.h4.9 KB
- lib/sph/Functions.h12.0 KB
- lib/sph/Particle.h43.4 KB
- lib/util/array.h29.7 KB
- lib/util/colors.h15.6 KB
- lib/util/fatal.h4.0 KB
- lib/util/maps.h23.9 KB
- lib/util/numstreams.h5.0 KB
- lib/util/stopwatch.h3.7 KB
- lib/util/string.h6.9 KB
- lib/util/tree.h7.7 KB
- lib/util/util.h8.7 KB
- lib/vtk/arrow.h7.1 KB
- lib/vtk/arrows.h6.2 KB
- lib/vtk/axes.h11.1 KB
- lib/vtk/cube.h4.9 KB
- lib/vtk/cylinder.h5.0 KB
- lib/vtk/disk.h5.4 KB
- lib/vtk/isosurf.h5.4 KB
- lib/vtk/line.h3.2 KB
- lib/vtk/plane.h6.0 KB
- lib/vtk/sgrid.h13.6 KB
- lib/vtk/sphere.h3.7 KB
- lib/vtk/spheres.h9.9 KB
- lib/vtk/text.h3.2 KB
- lib/vtk/text2d.h2.9 KB
- lib/vtk/triangulate.h4.5 KB
- lib/vtk/ugrid.h4.6 KB
- lib/vtk/win.h7.2 KB
- lib/vtkcelltype.h7.8 KB
- MECHSYS_HANDBOOK.md23.2 KB
- MEMORY.md12.1 KB
- Modules/FindBLITZ.cmake2.1 KB
- Modules/FindCGAL.cmake2.2 KB
- Modules/FindDEPS.cmake13.4 KB
- Modules/FindDEPSFL.cmake14.3 KB
- Modules/FindFLTK.cmake2.1 KB
- Modules/FindGMSH.cmake4.2 KB
- Modules/FindGOTOBLAS.cmake2.0 KB
- Modules/FindGSL.cmake2.5 KB
- Modules/FindHDF5.cmake3.1 KB
- Modules/FindIGRAPH.cmake2.4 KB
- Modules/FindLocLAPACK.cmake2.1 KB
- Modules/FindMECHSYS.cmake2.4 KB
- Modules/FindMTL.cmake2.0 KB
- Modules/FindMUMPS.cmake2.3 KB
- Modules/FindPARMETIS.cmake2.1 KB
- Modules/FindPROC.cmake2.2 KB
- Modules/FindSCALAPACK.cmake2.1 KB
- Modules/FindSOPLEX.cmake2.2 KB
- Modules/FindSPHASH.cmake2.0 KB
- Modules/FindSUPERLU.cmake2.4 KB
- Modules/FindSUPERLUD.cmake2.2 KB
- Modules/FindSUPERLUMT.cmake2.2 KB
- Modules/FindTENSORS.cmake2.0 KB
- Modules/FindUMFPACK.cmake2.8 KB
- Modules/FindVORO.cmake2.3 KB
- Modules/FindVTK.cmake3.1 KB
- Modules/mechsys-config.in3.3 KB
- Modules/mechsyscc.in6.9 KB
- msys_sandbox.zip3.4 KB
- patches/blitz/do_patch.bash293 B
- patches/blitz/funcs.h.diff33 B
- patches/blitz/mathfunc.h.diff30 B
- patches/blitz/range.h.diff166 B
- patches/igraph/community_leiden.c.diff628 B
- patches/igraph/do_patch.bash757 B
- patches/igraph/README.md1.5 KB
- patches/igraph/uninit.c.diff326 B
- patches/mumps/do_patch.bash128 B
- patches/mumps/Makefile.inc3.9 KB
- patches/superlumt/do_patch.bash633 B
- patches/superlumt/install_makefile.diff50 B
- patches/superlumt/install.bash251 B
- patches/superlumt/make.pthreads1.1 KB
- patches/superlumt/pctest.bash1.6 KB
- patches/superlumt/pdtest.bash1.6 KB
- patches/superlumt/pstest.bash1.6 KB
- patches/superlumt/pztest.bash1.6 KB
- patches/superlumt/test.bash58 B
- patches/superlumt/testing_makefile.diff492 B
- patches/voro/cell0.3.hh.diff283 B
- patches/voro/CMakeLists.txt85 B
- patches/voro/container0.3.hh.diff51 B
- patches/voro/do_patch.bash228 B
- patches/voro/src_CMakeLists.txt29 B
- README.txt815 B
- scripts/additional_installations.bash8.9 KB
- scripts/install_apt_deps.bash772 B
- scripts/install_compile_deps.bash11.3 KB
- scripts/install_flashlite.bash9.9 KB
- scripts/old/01_create_mechsys_deb.sh1.3 KB
- scripts/old/02_gen_repository.sh1.3 KB
- scripts/old/autocrop_convert_eps.bash97 B
- scripts/old/change_header.sh3.1 KB
SKILL.md(원문)
설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.
MechSys
This is the visible, downloadable copy of the MechSys skill. DSH discovers
.agents/skills/mechsys/SKILL.md; keep the two files in sync.
This is the project-local skill for the MechSys checkout. It is discovered
automatically from .agents/skills/mechsys; do not install a separate plugin
just to provide this static guidance.
The authoritative context is:
AGENTS.md— automatic, concise agent rules.MECHSYS_HANDBOOK.md— architecture, build/run commands, exactness procedure, benchmarks, and known traps.MEMORY.md— distilled experience and a short verification checklist.- The optimization reports:
CPU_DEM_OPTIMIZATION_CHANGES.mdCUDA_OPTIMIZATION_CHANGES.mdREDUCED_TEST_CU_03_PERFORMANCE.md
Read the relevant documents before making substantive changes, and update them when a durable lesson or corrected benchmark is learned.
Non-negotiable rules
- Do not assume a given checkout or
HEADcontains the optimized state. Checkgit status, the reports, and compare against a clean baseline created from the chosen commit. - CPU DEM exactness is checked at
Nproc=1by comparing HDF5 datasets, not whole-file MD5. Expectneq []and matching printed energies. - Preserve candidate-list order and the original
Distancearithmetic in the contact path. Do not sort the lists. - The CPU Verlet cutoff is
Rsum + 4.0*ContactDispGlobal(). Do not lower it without a new safe derivation and an exact comparison. - Broadphase bounds must be conservative. If in doubt, remove a rejection rather than risk a missed contact.
- CUDA
test_cu_03/04useatomicAdd; the baseline is non-deterministic. Do not claim bitwise equality for those GPU runs.Nthread=512fails for the current large test; tested range is up to 384. - Keep the separate
pTranslate+pRotatefallback. Making fused movement unconditional broketest_cu_04. - The outer solve loop owns
Time/iter; publish them to CUDA withSetClock. Do not add independent clock increments in DEM or LBM substeps. - After changing
lib/dem/*, build at least one CPU target, one CUDA target, and the relevant LBM-DEM target.
Rotation caches
Particle owns wrot = Rotation(w,Q) and Qc = Conjugate(Q). They are
refreshed by CalcProps, InitializeVelocity, Rotate, UpdateContacts, and
after a user Setup callback.
- CUDA
UploadParticlecopies the host caches; it does not recompute them. - CUDA
DnloadParticlecopies the device caches back. - The built-in device movement kernels refresh the device caches after
changing
Q/w. - A custom GPU movement/rotation kernel that changes
Q/wmust refreshDPar[].wrot/DPar[].Qcitself. - Host code that assigns
Q/wdirectly and bypasses the normal paths must callParticle::UpdateRotCache()before using the caches.
Build and run
From the repository root:
cd tdem
make -j8 test_periodic
make -j8 test_cu_01 test_cu_02 test_cu_03 test_cu_04
./test_periodic ../benchmarks/cpu_voronoi/tper_small 8
cd ../tlbmdem
make -j8 tlbmdem01 tlbmdem02
make -j8 tlbmdem_cu_01
test_periodic takes a FileKey prefix (the .inp suffix is appended).
test_cu_03 takes Nproc, Verlet distance, and threads per block:
./test_cu_03 1 0.05 128. Full LBM-DEM and CUDA tests are long; use a
temporary reduced copy for smoke tests and do not modify the checked-in test
just to shorten it.
For one-off cases, use the configured standalone compiler:
./mechsyscc case.cu from the repository root (or the equivalent
mechsyscc in the current installation).
FLBM / GPU fluid cases
lib/flbm/Domain.his the fluid LBM;lib/flbm/lbm.cuhholds the CUDA kernels. UseD2Q9withiVec3_t(nx,ny,1)for a 2-D GPU run.- The GPU streaming kernel resets
BForceevery step. A constant body force must be written back todom.pBForceon the device in theSetupcallback before collision; setting the host array once is not enough. dom.Nthreadcontrols the CUDA block size. TheNprocargument ofDomain::Solveaffects host packing/transfers on the GPU path.- CPU and GPU body-force conventions differ: CPU
StreamSCadds0.5*dt*BForceto the reported velocity, while the GPU fused kernel returns the raw second moment. The raw GPU moment carries a-0.5*nu*phibias in permeability; useu_physical = u_raw + 0.5*dt*fx*phi. - Keep one-off FLBM cases outside the checkout; do not add them to
tflbm/unless they belong in the library test suite.
Reporting
Report measured wall times, separate solve time from total wall time, and explicitly distinguish what compiled, what ran, what matched a baseline, and what was faster. If a verification was not done, say so.
리뷰
아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.
댓글
로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.
아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.