Scikit-learn
Joblib
dom_ml
mass-spectrometry
molecular-formula
dissolved-organic-matter
machine-learning
scikit-learn
custom_code
Instructions to use SaeedLab/dom-formula-assignment-using-ml with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Scikit-learn
How to use SaeedLab/dom-formula-assignment-using-ml with Scikit-learn:
from huggingface_hub import hf_hub_download import joblib model = joblib.load( hf_hub_download("SaeedLab/dom-formula-assignment-using-ml", "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
Download configuration_dom_ml.py from SaeedLab/dom-formula-assignment-using-ml: direct link, hf CLI and curl.
- Browser
- Download file 498 Bytes
-
https://huggingface.co/SaeedLab/dom-formula-assignment-using-ml/resolve/main/configuration_dom_ml.py
- Command line
-
hf download hf://SaeedLab/dom-formula-assignment-using-ml/configuration_dom_ml.py
-
curl -L -o configuration_dom_ml.py https://huggingface.co/SaeedLab/dom-formula-assignment-using-ml/resolve/main/configuration_dom_ml.py
498 Bytes
| from transformers import PretrainedConfig | |
| class DomMLConfig(PretrainedConfig): | |
| model_type = "dom_ml" | |
| def __init__( | |
| self, | |
| model_name="Synthetic_K3_Euclidean_Ensemble", | |
| model_file=None, | |
| feature_names=None, | |
| model_kind=None, | |
| **kwargs, | |
| ): | |
| super().__init__(**kwargs) | |
| self.model_name = model_name | |
| self.model_file = model_file | |
| self.model_kind = model_kind | |
| self.feature_names = feature_names or ["mass"] | |