Instructions to use aduzlo/zello-valid-trial-v3.2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Scikit-learn
How to use aduzlo/zello-valid-trial-v3.2 with Scikit-learn:
from huggingface_hub import hf_hub_download import joblib model = joblib.load( hf_hub_download("aduzlo/zello-valid-trial-v3.2", "sklearn_model.joblib") ) # only load pickle files from sources you trust # read more about it here https://skops.readthedocs.io/en/stable/persistence.html - Notebooks
- Google Colab
- Kaggle
Delete vtc
Browse files- vtc/__init__.py +0 -0
- vtc/vtc.py +0 -15
vtc/__init__.py
DELETED
|
File without changes
|
vtc/vtc.py
DELETED
|
@@ -1,15 +0,0 @@
|
|
| 1 |
-
from sklearn.base import BaseEstimator, ClassifierMixin
|
| 2 |
-
|
| 3 |
-
class ValidTrialClassifier(BaseEstimator, ClassifierMixin):
|
| 4 |
-
|
| 5 |
-
def __init__(self, classifier, threshold = 0.5):
|
| 6 |
-
self.classifier = classifier
|
| 7 |
-
self.threshold = threshold
|
| 8 |
-
|
| 9 |
-
def fit(self, X, y):
|
| 10 |
-
self.classifier.fit(X, y)
|
| 11 |
-
return self
|
| 12 |
-
|
| 13 |
-
def predict(self, X):
|
| 14 |
-
pred = self.classifier.predict_proba(X)[:, 1]
|
| 15 |
-
return pred > self.threshold
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|