Skip to content

Commit

Permalink
style: format code with Autopep8, Black, ClangFormat, dotnet-format, …
Browse files Browse the repository at this point in the history
…Go fmt, Gofumpt, Google Java Format, isort, Ktlint, PHP CS Fixer, Prettier, RuboCop, Ruff Formatter, Rustfmt, Scalafmt, StandardJS, StandardRB, swift-format and Yapf

This commit fixes the style issues introduced in 5e79cd2 according to the output
from Autopep8, Black, ClangFormat, dotnet-format, Go fmt, Gofumpt, Google Java
Format, isort, Ktlint, PHP CS Fixer, Prettier, RuboCop, Ruff Formatter, Rustfmt,
Scalafmt, StandardJS, StandardRB, swift-format and Yapf.

Details: None
  • Loading branch information
deepsource-autofix[bot] authored May 10, 2024
1 parent 5e79cd2 commit 2f9145a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions fraud_detection/fraud_detection_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@
from sklearn.ensemble import RandomForestClassifier
from sklearn.model_selection import train_test_split


class FraudDetectionModel:
def __init__(self, data):
self.data = data
self.X = self.data.drop('fraudulent', axis=1)
self.y = self.data['fraudulent']
self.X = self.data.drop("fraudulent", axis=1)
self.y = self.data["fraudulent"]

def train_model(self):
X_train, X_test, y_train, y_test = train_test_split(self.X, self.y, test_size=0.2, random_state=42)
X_train, X_test, y_train, y_test = train_test_split(
self.X, self.y, test_size=0.2, random_state=42
)
self.model = RandomForestClassifier(n_estimators=100, random_state=42)
self.model.fit(X_train, y_train)

Expand Down

0 comments on commit 2f9145a

Please sign in to comment.