1. 10 Feb, 2026 1 commit
    • Evan Pretti's avatar
      GPU implementation of L-BFGS (#5198) · 4ab645ea
      Evan Pretti authored
      * Make reference/CPU minimizer into a kernel
      
      * Add per-platform support for GPU minimization
      
      * Initial implementation of GPU minimization
      
      * Fixes
      
      * Increase robustness when initial gradient is huge
      
      * Handle overflow leading to non-finite values gracefully
      
      * Handle large forces in single precision more robustly
      
      * Optimize kernels
      
      * Fix kernel launch size
      
      * Update banner years
      
      * Don't create MinimizeKernel until first minimization requested
      
      * Make some compile-time constants into kernel arguments
      
      * Consolidate scale calculation kernel
      
      * Condense alpha/beta reduction kernels using atomics
      
      * Condense line search dot kernels with reductions
      
      * Remove a download, and download grad norm separately
      
      * Asynchronously check lbfgs convergence condition
      
      * Restructure line search to avoid download waiting
      
      * Start line search preemptively in case CPU evaluation is not needed
      
      * In rare cases, constraint error might not decrease after one optimization round
      
      * Better handling of unsupported 64-bit atomics, use FLT_MAX
      
      * Pick gradient mode based on GPU vs. CPU evaluation
      
      * Rework getDiff/getScale reduction, remove reduceBuffer
      
      * Older CUDA might not like float hex literals
      
      * Fix error in a comment
      4ab645ea
  2. 23 Sep, 2025 1 commit
  3. 12 Sep, 2025 1 commit
    • Evan Pretti's avatar
      Add constant potential method (#4870) · f55abcaa
      Evan Pretti authored
      
      
      * Initial implementation of C++ API
      
      * Add kernel interface and information for API generation
      
      * API updates for updating electrode parameters
      
      * Add serialization proxy for ConstantPotentialForce
      
      * Update file headers
      
      * Add CG error tolerance and fix units on getCharges() return value
      
      * Initial implementation of matrix solver
      
      * Fixes and conjugate gradient solver
      
      * Try to fix Linux and Windows builds
      
      * Make sure charge constraint target is on total charge
      
      * Restore handling of exceptions like NonbondedForce since they won't involve electrode atoms
      
      * Ameliorate numerical instability in constrained conjugate gradient
      
      * Fix uninitialized pointers, memory leak, and style
      
      * Set CG tolerance units in Python API
      
      * Test ConstantPotentialForce serialization
      
      * Read/write ExceptionsUsePeriodicBoundaryConditions as bool
      
      * Improve constrained conjugate gradient robustness to roundoff error accumulation
      
      * Recompute matrix if electrode atoms move due to setPositions()
      
      * Tolerance is now in gradient (potential) units again
      
      * Add neutralizing background correction
      
      * Add Python API tests
      
      * Fixes for CG and nonbonded exceptions
      
      * Add initial tests checking against existing NonbondedForce behavior
      
      * Expand test suite and fix some implementation issues
      
      * Add additional tests using larger reference system
      
      * Add Gaussian test
      
      * Finish test against reference computation
      
      * CPU platform implementation
      
      * Fixes for compilation on some platforms
      
      * Fixes for constant potential with AVX/AVX2
      
      * Test linking CPU PME library to constant potential test directly
      
      * Older SWIG versions don't support Python set to C++ set conversion
      
      * Add user guide entry
      
      * Increase speed of reference test
      
      * Conditional building constant potential CPU test is unreliable
      
      * Debugging
      
      * Miscellaneous fixes and improvements for CI
      
      * Cache charges so solver will not run if system and coordinates have not changed
      
      * Preconditioner flag, stability, and automatic detection improvements
      
      * Add GPU platform-specific constant potential kernel classes
      
      * PME and device-host I/O changes to support constant potential
      
      * Initial common constant potential implementation
      
      * Constant potential fixes:
      
      * Fix preconditioner PME position/charge save/restore logic
      
      * Fix reduction synchronization in constant potential solver kernels
      
      * Add double-float accumulation for conjugate gradient solver when
        double unsupported by hardware
      
      * Improve conditioning of a test system, and make sure particles are in or
      out of cutoff for consistency and ease of comparing between platforms
      
      * Reorder guess charges for CG when atom reordering changes positions
      
      * Remove PME queue for now
      
      * Trying to debug optimized direct space derivative kernel
      
      * Remove extraneous debugging lines
      
      * Style updates; just make CPU preconditioner double precision
      
      * Debugging updated optimized direct derivatives kernel for all but OpenCL CPU
      
      * OpenCL CPU implementation of direct space derivatives, and cleanup
      
      * Try to make test even shorter to not time out on CI
      
      * Temporary - Debugging
      
      * Debugging
      
      * Debugging
      
      * Debugging
      
      * Debugging
      
      * Remove debugging code and fix reduction synchronization
      
      * Fix other reductions
      
      * Debugging - are tests hanging or just slow on CI?
      
      * Debugging
      
      * Debugging
      
      * Fix macro for case when double precision is available on hardware
      
      * Remove changes for debugging again
      
      * Try to improve matrix solver cache locality by uploading transpose
      
      * Fixes for atom ordering and periodic images
      
      * Can't rely on reorder listener for cell offset updates
      
      * Test reducing number of contexts and timing for CI
      
      * Debugging
      
      * Remove timing code and revert debugging changes
      
      * Matrix solver and plasma term optimizations
      
      * Reduce CG solver kernel calls and downloads
      
      * Don't read back convergence flag from global memory
      
      * Update PME due to refactoring in master branch
      
      * Faster matrix solver (1st step)
      
      * Faster matrix solver for CUDA
      
      * Faster matrix solver compatibility with non-CUDA platforms
      
      * Matrix solver fixes
      
      * Use warp shuffle reductions when possible
      
      * Attempt to work around intermittent compiler crash in Intel CPU OpenCL
      
      * Optimize CG solver kernel 1
      
      * Rework CG solver so some kernels can use more than 1 block
      
      * Don't run out of shared memory
      
      * Asynchronously download convergence flag while clearing buffers
      
      ---------
      Co-authored-by: default avatarEvan Pretti <pretti@sh03-17n15.int>
      f55abcaa
  4. 10 Mar, 2025 1 commit
  5. 27 Nov, 2024 1 commit
  6. 05 Sep, 2024 1 commit
  7. 22 Jan, 2024 1 commit
  8. 30 Nov, 2023 1 commit
  9. 31 Jan, 2023 1 commit
  10. 15 Nov, 2022 1 commit
  11. 30 Jun, 2022 1 commit
    • Peter Eastman's avatar
      Use PocketFFT (#3667) · 1dac981a
      Peter Eastman authored
      * Use PocketFFT instead of FFTW
      
      * Minor cleanup
      
      * Use PocketFFT instead of fftpack for reference platform
      
      * Remove FFTW as a dependency
      
      * Converted a test case to use PocketFFT
      
      * Fixed an incorrect comment
      1dac981a
  12. 14 Apr, 2022 1 commit
    • Peter Eastman's avatar
      Vectorized CpuCustomNonbondedForce (#3568) · c8981916
      Peter Eastman authored
      * Began vectorizing CustomNonbondedForce
      
      * Refactored CpuCustomNonbondedForce to support multiple vector sizes
      
      * AVX implementation of CpuCustomNonbondedForce
      
      * Fixed compilation errors
      c8981916
  13. 10 Apr, 2022 1 commit
    • Peter Eastman's avatar
      Vectorize custom expressions on CPU (#3552) · aafb8b5b
      Peter Eastman authored
      * Began implementing vectorization of Lepton expressions
      
      * Tests for vector expressions
      
      * Implemented CompiledVectorExpression for x86
      
      * Bug fix
      
      * Optimized select() on ARM
      
      * Optimized select() on x86
      
      * CompiledVectorExpression supports AVX
      
      * Bug fix
      
      * Updated docs
      
      * Use VEX encoded instructions for CompiledExpression
      
      * Optimized min() and max() on x86
      
      * Optimized min() and max() on ARM
      
      * Fixed compilation error
      
      * Upgrade AsmJit
      aafb8b5b
  14. 18 Mar, 2022 1 commit
  15. 17 Mar, 2022 1 commit
  16. 08 Sep, 2021 1 commit
  17. 02 Mar, 2021 1 commit
  18. 01 Jun, 2020 1 commit
  19. 11 May, 2020 1 commit
  20. 13 Apr, 2020 1 commit
  21. 01 Apr, 2020 1 commit
  22. 28 Mar, 2020 1 commit
  23. 08 Jan, 2020 1 commit
    • peastman's avatar
      Common compute framework to unify CUDA and OpenCL code (#2488) · edbc8407
      peastman authored
      * Began creating common compute framework to unify code between CUDA and OpenCL
      
      * Began OpenCL implementation of common compute framework
      
      * Common implementation of CMMotionRemover
      
      * CUDA implementation of common compute interface
      
      * Converted HarmonicBondForce to common compute API
      
      * Converted standard bonded forces to common compute API
      
      * Converted ExpressionUtilities to common compute API
      
      * Created ComputeParameterSet
      
      * Converted custom bonded forces to common compute API
      
      * Converted CustomCentroidBondForce to common compute API
      
      * Converted CustomManyParticleForce to common compute API
      
      * Moved lots of duplicate code from CudaContext and OpenCLContext to ComputeContext
      
      * Converted GayBerneForce to common compute API
      
      * Removed obsolete kernels
      
      * Converted verlet integrators to common compute API
      
      * Converted Langevin and Brownian integrators to common compute API
      
      * Converted CustomIntegrator to common compute API
      
      * Converted CustomNonbondedForce to common compute API
      
      * Removed uses of a deprecated API
      
      * Fixed failing test cases
      
      * Converted GBSAOBCForce to common compute API
      
      * Began converting CustomGBForce to common compute API
      
      * Finished converting CustomGBForce to common compute API
      
      * Merged duplicated code in CudaIntegrationUtilities and OpenCLIntegrationUtilities
      
      * Converted RMSDForce and AndersenThermostat to common compute API
      
      * Converted CustomHbondForce to common compute API
      
      * Merged scripts for encoding kernel sources
      
      * Converted Drude plugin to common compute API
      
      * Fixed errors in CMake scripts
      
      * Attempt at fixing errors on Windows
      
      * Added discussion of common compute API to developer guide
      
      * Added Windows export macro for common classes
      
      * Fixed error in CMMotionRemover
      
      * Ubdated travis to newer Ubuntu version
      
      * Fixed errors on CPU OpenCL
      
      * Fixed Windows linking errors
      
      * Added missing pragma for 32 bit atomics
      
      * Replaced long long with mm_long
      
      * More fixes to Windows linking
      
      * Bug fix
      edbc8407
  24. 12 Dec, 2019 1 commit
    • Jérôme Hénin's avatar
      Fix Lepton optimization with -ffast-math · 144fa34a
      Jérôme Hénin authored
      Lepton::ParsedExpression::getConstantValue() used to return NaN to indicate non-constant
      expressions. This can break with -ffast-math optimization where NaN comparisons are
      not defined.
      
      This patch defines bool isConstant() to test whether an expression is constant before
      calling getConstantValue(). getConstantValue() now throws an exception if called on a
      non-constant expression.
      144fa34a
  25. 01 Jun, 2019 1 commit
  26. 21 Mar, 2019 1 commit
  27. 20 Mar, 2019 1 commit
  28. 23 Jul, 2018 1 commit
  29. 03 Jul, 2018 1 commit
  30. 27 Apr, 2018 1 commit
  31. 10 Feb, 2017 1 commit
  32. 07 Sep, 2016 1 commit
  33. 10 Aug, 2016 1 commit
  34. 25 Jul, 2016 1 commit
  35. 03 Jun, 2016 1 commit
  36. 25 Apr, 2016 1 commit
  37. 08 Feb, 2016 1 commit
  38. 19 Nov, 2015 1 commit
  39. 11 Nov, 2015 2 commits