Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enforced Python/C++/CUDA Code Formatting with Black and Clang #99

Merged
merged 1 commit into from
Sep 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion memtorch/cpp/solve_sparse_linear.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
#include <Eigen/SparseCore>
#include <Eigen/SparseQR>

void solve_sparse_linear(Eigen::SparseMatrix<double> A, double *B_values, int n);
void solve_sparse_linear(Eigen::SparseMatrix<double> A, double *B_values,
int n);
void solve_sparse_linear(Eigen::SparseMatrix<float> A, float *B_values, int n);
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ def create_version_py(version, CUDA):

create_version_py(version, CUDA)
if CUDA:
from torch.utils.cpp_extension import (BuildExtension, CppExtension,
CUDAExtension)
from torch.utils.cpp_extension import BuildExtension, CppExtension, CUDAExtension

ext_modules = [
CUDAExtension(
Expand Down
10 changes: 6 additions & 4 deletions tests/test_nonidealities.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@

import memtorch
from memtorch.bh.nonideality.DeviceFaults import apply_cycle_variability
from memtorch.bh.nonideality.endurance_retention_models.conductance_drift import \
model_conductance_drift
from memtorch.bh.nonideality.endurance_retention_models.empirical_metal_oxide_RRAM import \
model_endurance_retention
from memtorch.bh.nonideality.endurance_retention_models.conductance_drift import (
model_conductance_drift,
)
from memtorch.bh.nonideality.endurance_retention_models.empirical_metal_oxide_RRAM import (
model_endurance_retention,
)
from memtorch.bh.nonideality.NonIdeality import apply_nonidealities
from memtorch.mn.Module import supported_module_parameters

Expand Down