Skip to content

Commit

Permalink
Merge pull request #1908 from glotzerlab/pre-commit-ci-update-config
Browse files Browse the repository at this point in the history
[pre-commit.ci] pre-commit autoupdate
  • Loading branch information
joaander authored Oct 7, 2024
2 parents 2d9d4df + 76c0bac commit 967b6a4
Show file tree
Hide file tree
Showing 47 changed files with 77 additions and 79 deletions.
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ repos:
language: pygrep
types_or: [python, c, c++, cuda, inc]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v4.6.0'
rev: 'v5.0.0'
hooks:
- id: end-of-file-fixer
exclude_types: [svg]
Expand All @@ -30,7 +30,7 @@ repos:
- id: check-case-conflict
- id: mixed-line-ending
- repo: https://github.com/glotzerlab/fix-license-header
rev: v0.4.0
rev: v0.4.1
hooks:
- id: fix-license-header
name: Fix license headers
Expand All @@ -55,7 +55,7 @@ repos:
hooks:
- id: yapf
- repo: https://github.com/PyCQA/flake8
rev: '7.1.0'
rev: '7.1.1'
hooks:
- id: flake8
additional_dependencies:
Expand All @@ -72,7 +72,7 @@ repos:
^hoomd/metal/
)
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v18.1.8
rev: v19.1.1
hooks:
- id: clang-format
types_or: [c, c++, cuda, inc]
Expand Down
4 changes: 2 additions & 2 deletions hoomd/Analyzer.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class PYBIND11_EXPORT Analyzer : public Action
public:
//! Constructs the analyzer and associates it with the ParticleData
Analyzer(std::shared_ptr<SystemDefinition> sysdef, std::shared_ptr<Trigger> trigger);
virtual ~Analyzer() {};
virtual ~Analyzer() { };

//! Abstract method that performs the analysis
/*! Derived classes will implement this method to calculate their results
Expand Down Expand Up @@ -89,7 +89,7 @@ class PYBIND11_EXPORT Analyzer : public Action
}

/// Python will notify C++ objects when they are detached from Simulation
virtual void notifyDetach() {};
virtual void notifyDetach() { };

/// Get Trigger
std::shared_ptr<Trigger> getTrigger()
Expand Down
2 changes: 1 addition & 1 deletion hoomd/Autotuner.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class PYBIND11_EXPORT AutotunerBase
}

/// Set autother parameters from a Python tuple.
virtual void setParameterPython(pybind11::tuple parameter) {};
virtual void setParameterPython(pybind11::tuple parameter) { };
#endif

#ifdef ENABLE_HIP
Expand Down
2 changes: 1 addition & 1 deletion hoomd/CellListGPU.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class PYBIND11_EXPORT CellListGPU : public CellList
//! Construct a cell list
CellListGPU(std::shared_ptr<SystemDefinition> sysdef);

virtual ~CellListGPU() {};
virtual ~CellListGPU() { };

//! Request a multi-GPU cell list
virtual void setPerDevice(bool per_device)
Expand Down
2 changes: 1 addition & 1 deletion hoomd/Compute.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ class PYBIND11_EXPORT Compute : public Action
void forceCompute(uint64_t timestep);

/// Python will notify C++ objects when they are detached from Simulation
virtual void notifyDetach() {};
virtual void notifyDetach() { };

protected:
bool m_force_compute; //!< true if calculation is enforced
Expand Down
2 changes: 1 addition & 1 deletion hoomd/GPUArray.h
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ template<class T, class Derived> class GPUArrayBase

private:
// Make constructor private to prevent mistakes
GPUArrayBase() {};
GPUArrayBase() { };
friend Derived;
};

Expand Down
2 changes: 1 addition & 1 deletion hoomd/GPUFlags.h
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ template<class T> void GPUFlags<T>::deallocate()
if (h_data == NULL)
return;

// free memory
// free memory
#ifdef ENABLE_HIP
if (m_exec_conf && m_exec_conf->isCUDAEnabled())
{
Expand Down
2 changes: 1 addition & 1 deletion hoomd/HalfStepHook.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class PYBIND11_EXPORT HalfStepHook
// Synchronize snapshot with external library after computing forces
virtual void update(uint64_t timestep) = 0;

virtual ~HalfStepHook() {};
virtual ~HalfStepHook() { };
};

} // namespace hoomd
Expand Down
2 changes: 1 addition & 1 deletion hoomd/MPIConfiguration.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class PYBIND11_EXPORT MPIConfiguration
);

//! Destructor
virtual ~MPIConfiguration() {};
virtual ~MPIConfiguration() { };

#ifdef ENABLE_MPI
MPI_Comm operator()() const
Expand Down
2 changes: 1 addition & 1 deletion hoomd/Tuner.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class PYBIND11_EXPORT Tuner : public Updater
public:
//! Constructs the compute and associates it with the ParticleData
Tuner(std::shared_ptr<SystemDefinition> sysdef, std::shared_ptr<Trigger> trigger);
virtual ~Tuner() {};
virtual ~Tuner() { };
};

namespace detail
Expand Down
6 changes: 3 additions & 3 deletions hoomd/Updater.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ class PYBIND11_EXPORT Updater : public Action
public:
//! Constructs the compute and associates it with the ParticleData
Updater(std::shared_ptr<SystemDefinition> sysdef, std::shared_ptr<Trigger> trigger);
virtual ~Updater() {};
virtual ~Updater() { };

//! Abstract method that performs the update
/*! Derived classes will implement this method to perform their specific update
\param timestep Current time step of the simulation
*/
virtual void update(uint64_t timestep) {};
virtual void update(uint64_t timestep) { };

//! Reset stat counters
/*! If derived classes provide statistics for the last run, they should resetStats() to
Expand Down Expand Up @@ -100,7 +100,7 @@ class PYBIND11_EXPORT Updater : public Action
}

/// Python will notify C++ objects when they are detached from Simulation
virtual void notifyDetach() {};
virtual void notifyDetach() { };

/// Return true if updating should trigger a recount of the degrees of freedom.
virtual bool mayChangeDegreesOfFreedom(uint64_t timestep)
Expand Down
2 changes: 1 addition & 1 deletion hoomd/filter/ParticleFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class PYBIND11_EXPORT ParticleFilter
{
public:
/// constructs a base ParticleFilter (does nothing)
ParticleFilter() {};
ParticleFilter() { };
virtual ~ParticleFilter() { }

/** Test if a particle meets the selection criteria.
Expand Down
2 changes: 1 addition & 1 deletion hoomd/filter/ParticleFilterAll.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class PYBIND11_EXPORT ParticleFilterAll : public ParticleFilter
{
public:
/// Constructs the selector
ParticleFilterAll() : ParticleFilter() {};
ParticleFilterAll() : ParticleFilter() { };
virtual ~ParticleFilterAll() { }

/** Args:
Expand Down
2 changes: 1 addition & 1 deletion hoomd/filter/ParticleFilterCustom.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class PYBIND11_EXPORT ParticleFilterCustom : public ParticleFilter
public:
/// constructs a custom ParticleFilter
ParticleFilterCustom(pybind11::object py_filter, pybind11::object state)
: m_py_filter(py_filter), m_state(state) {};
: m_py_filter(py_filter), m_state(state) { };

virtual ~ParticleFilterCustom() { }

Expand Down
2 changes: 1 addition & 1 deletion hoomd/filter/ParticleFilterNull.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class PYBIND11_EXPORT ParticleFilterNull : public ParticleFilter
{
public:
/// Constructs the selector
ParticleFilterNull() : ParticleFilter() {};
ParticleFilterNull() : ParticleFilter() { };
virtual ~ParticleFilterNull() { }

/** Args:
Expand Down
2 changes: 1 addition & 1 deletion hoomd/filter/ParticleFilterRigid.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class PYBIND11_EXPORT ParticleFilterRigid : public ParticleFilter
{
public:
/// constructs a ParticleFilterRigid
ParticleFilterRigid(RigidBodySelection flag) : m_current_selection {flag} {};
ParticleFilterRigid(RigidBodySelection flag) : m_current_selection {flag} { };

ParticleFilterRigid(pybind11::tuple flags) : m_current_selection(RigidBodySelection::NONE)
{
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/ComputeFreeVolume.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ template<class Shape> class ComputeFreeVolume : public Compute
std::shared_ptr<IntegratorHPMCMono<Shape>> mc,
std::shared_ptr<CellList> cl);
//! Destructor
virtual ~ComputeFreeVolume() {};
virtual ~ComputeFreeVolume() { };

//! Get the number of MC samples to perform
unsigned int getNumSamples()
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/ComputeFreeVolumeGPU.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ struct hpmc_free_volume_args_t
select(_select), timestep(_timestep), dim(_dim), box(_box), block_size(_block_size),
stride(_stride), group_size(_group_size), max_n(_max_n),
d_n_overlap_all(_d_n_overlap_all), ghost_width(_ghost_width),
d_check_overlaps(_d_check_overlaps), overlap_idx(_overlap_idx), devprop(_devprop) {};
d_check_overlaps(_d_check_overlaps), overlap_idx(_overlap_idx), devprop(_devprop) { };

unsigned int n_sample; //!< Number of depletants particles to generate
unsigned int type; //!< Type of depletant particle
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/ComputeSDF.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ template<class Shape> class ComputeSDF : public Compute
double dx);

//! Destructor
virtual ~ComputeSDF() {};
virtual ~ComputeSDF() { };

//! Get the maximum value in the rightmost histogram bin
double getXMax()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ struct hpmc_auxilliary_args_t
d_n_depletants_ntrial(_d_n_depletants_ntrial), d_deltaF_int(_d_deltaF_int),
streams_phase1(_streams_phase1), streams_phase2(_streams_phase2), max_len(_max_len),
d_req_len(_d_req_len), add_ghosts(_add_ghosts), n_ghosts(_n_ghosts),
gpu_partition_rank(_gpu_partition_rank) {};
gpu_partition_rank(_gpu_partition_rank) { };

const unsigned int* d_tag; //!< Particle tags
const Scalar4* d_vel; //!< Particle velocities (.x component is the auxilliary variable)
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/IntegratorHPMCMonoGPUDepletantsTypes.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ struct hpmc_implicit_args_t
: depletant_type_a(_depletant_type_a), d_implicit_count(_d_implicit_count),
implicit_counters_pitch(_implicit_counters_pitch), repulsive(_repulsive),
d_n_depletants(_d_n_depletants), max_n_depletants(_max_n_depletants),
depletants_per_thread(_depletants_per_thread), streams(_streams) {};
depletants_per_thread(_depletants_per_thread), streams(_streams) { };

const unsigned int depletant_type_a; //!< Particle type of first depletant
hpmc_implicit_counters_t* d_implicit_count; //!< Active cell acceptance/rejection counts
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/IntegratorHPMCMonoGPUTypes.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ struct hpmc_args_t
d_trial_move_type(_d_trial_move_type), d_update_order_by_ptl(_d_update_order_by_ptl),
d_excell_idx(_d_excell_idx), d_excell_size(_d_excell_size), excli(_excli),
d_reject_in(_d_reject_in), d_reject_out(_d_reject_out), devprop(_devprop),
gpu_partition(_gpu_partition), streams(_streams) {};
gpu_partition(_gpu_partition), streams(_streams) { };

const Scalar4* d_postype; //!< postype array
const Scalar4* d_orientation; //!< orientation array
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/ShapeMoves.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ template<typename Shape> class ShapeMoveBase
m_step_size.resize(m_ntypes, 0);
}

virtual ~ShapeMoveBase() {};
virtual ~ShapeMoveBase() { };

//! prepare is called at the beginning of every update()
virtual void prepare(uint64_t timestep) { }
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/ShapePolyhedron.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ namespace detail
*/
struct TriangleMesh : ShapeParams
{
TriangleMesh() : face_verts(), face_overlap(), n_faces(0), ignore(0) {};
TriangleMesh() : face_verts(), face_overlap(), n_faces(0), ignore(0) { };

#ifndef __HIPCC__
/** Initialize with a given number of vertices and vaces
Expand Down
6 changes: 3 additions & 3 deletions hoomd/hpmc/ShapeUtils.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class MassPropertiesBase
m_inertia.resize(6, 0.0);
}

virtual ~MassPropertiesBase() {};
virtual ~MassPropertiesBase() { };

Scalar getVolume()
{
Expand Down Expand Up @@ -86,7 +86,7 @@ template<class Shape> class MassProperties : public MassPropertiesBase
template<> class MassProperties<ShapeConvexPolyhedron> : public MassPropertiesBase
{
public:
MassProperties() : MassPropertiesBase() {};
MassProperties() : MassPropertiesBase() { };

MassProperties(const typename ShapeConvexPolyhedron::param_type& param) : MassPropertiesBase()
{
Expand Down Expand Up @@ -244,7 +244,7 @@ template<> class MassProperties<ShapeConvexPolyhedron> : public MassPropertiesBa
template<> class MassProperties<ShapeEllipsoid> : public MassPropertiesBase
{
public:
MassProperties() : MassPropertiesBase() {};
MassProperties() : MassPropertiesBase() { };

MassProperties(const typename ShapeEllipsoid::param_type& param)
: MassPropertiesBase(), m_param(param)
Expand Down
2 changes: 1 addition & 1 deletion hoomd/hpmc/UpdaterClustersGPU.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ struct cluster_args_t
d_excell_idx(_d_excell_idx), d_excell_size(_d_excell_size), excli(_excli),
d_adjacency(_d_adjacency), d_nneigh(_d_nneigh), maxn(_maxn), d_overflow(_d_overflow),
dim(_dim), line(_line), pivot(_pivot), q(_q), update_shape_param(_update_shape_param),
devprop(_devprop), gpu_partition(_gpu_partition), streams(_streams) {};
devprop(_devprop), gpu_partition(_gpu_partition), streams(_streams) { };

const Scalar4* d_postype; //!< postype array
const Scalar4* d_orientation; //!< orientation array
Expand Down
2 changes: 1 addition & 1 deletion hoomd/md/AlchemostatTwoStep.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AlchemostatTwoStep : public IntegrationMethodTwoStep
: IntegrationMethodTwoStep(
sysdef,
std::make_shared<ParticleGroup>(sysdef, std::make_shared<ParticleFilterNull>())),
m_nTimeFactor(alchemTimeFactor), m_halfDeltaT(0.5 * m_deltaT * alchemTimeFactor) {};
m_nTimeFactor(alchemTimeFactor), m_halfDeltaT(0.5 * m_deltaT * alchemTimeFactor) { };

virtual ~AlchemostatTwoStep() { }

Expand Down
6 changes: 3 additions & 3 deletions hoomd/md/AlchemyData.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ namespace md
struct AlchemicalParticle
{
AlchemicalParticle(std::shared_ptr<const ExecutionConfiguration> exec_conf)
: value(Scalar(1.0)), m_attached(true), m_exec_conf(exec_conf) {};
: value(Scalar(1.0)), m_attached(true), m_exec_conf(exec_conf) { };

void notifyDetach()
{
Expand All @@ -52,7 +52,7 @@ struct AlchemicalMDParticle : AlchemicalParticle
{
AlchemicalMDParticle(std::shared_ptr<const ExecutionConfiguration> exec_conf)

: AlchemicalParticle(exec_conf) {};
: AlchemicalParticle(exec_conf) { };

void inline zeroForces()
{
Expand Down Expand Up @@ -136,7 +136,7 @@ struct AlchemicalPairParticle : AlchemicalMDParticle
{
AlchemicalPairParticle(std::shared_ptr<const ExecutionConfiguration> exec_conf,
int3 type_pair_param)
: AlchemicalMDParticle(exec_conf), m_type_pair_param(type_pair_param) {};
: AlchemicalMDParticle(exec_conf), m_type_pair_param(type_pair_param) { };
int3 m_type_pair_param;
};

Expand Down
2 changes: 1 addition & 1 deletion hoomd/md/AnisoPotentialPairGPU.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ struct a_pair_args_t
d_head_list(_d_head_list), d_rcutsq(_d_rcutsq), ntypes(_ntypes), block_size(_block_size),
shift_mode(_shift_mode), compute_virial(_compute_virial),
threads_per_particle(_threads_per_particle), gpu_partition(_gpu_partition),
devprop(_devprop), update_shape_param(_update_shape_param) {};
devprop(_devprop), update_shape_param(_update_shape_param) { };

Scalar4* d_force; //!< Force to write out
Scalar4* d_torque; //!< Torque to write out
Expand Down
2 changes: 1 addition & 1 deletion hoomd/md/AnisoPotentialPairGPU.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ template<class evaluator> class AnisoPotentialPairGPU : public AnisoPotentialPai
AnisoPotentialPairGPU(std::shared_ptr<SystemDefinition> sysdef,
std::shared_ptr<NeighborList> nlist);
//! Destructor
virtual ~AnisoPotentialPairGPU() {};
virtual ~AnisoPotentialPairGPU() { };

virtual void
setParams(unsigned int typ1, unsigned int typ2, const typename evaluator::param_type& param);
Expand Down
Loading

0 comments on commit 967b6a4

Please sign in to comment.