Text Classification
Transformers
Safetensors
PyTorch
English
distilbert
Generated from Trainer
text-embeddings-inference
Instructions to use CDRI-Eddy/ingredients_classification_model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use CDRI-Eddy/ingredients_classification_model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="CDRI-Eddy/ingredients_classification_model")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("CDRI-Eddy/ingredients_classification_model") model = AutoModelForSequenceClassification.from_pretrained("CDRI-Eddy/ingredients_classification_model", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -62,22 +62,4 @@ The following hyperparameters were used during training:
|
|
| 62 |
- Transformers 4.35.0
|
| 63 |
- Pytorch 2.1.0
|
| 64 |
- Datasets 2.14.6
|
| 65 |
-
- Tokenizers 0.14.1
|
| 66 |
-
|
| 67 |
-
## Inference API
|
| 68 |
-
์ด ์น์
์์๋ `bert-base-uncased` ๋ชจ๋ธ์ ์ฌ์ฉํ์ฌ ํ
์คํธ ๋ถ๋ฅ ์์
์ ์ํํ๋ ๋ฐฉ๋ฒ์ ๋ณด์ฌ์ฃผ๋ ์์ ์ฝ๋๋ฅผ ๋ณ๊ฒฝํ ์ ์์ต๋๋ค.
|
| 69 |
-
|
| 70 |
-
```python
|
| 71 |
-
from transformers import AutoModelForSequenceClassification, AutoTokenizer, pipeline
|
| 72 |
-
|
| 73 |
-
model_name = "CDRI-Eddy/ingredients_classification_model"
|
| 74 |
-
model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
| 75 |
-
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
| 76 |
-
|
| 77 |
-
nlp = pipeline("text-classification", model=model, tokenizer=tokenizer)
|
| 78 |
-
|
| 79 |
-
# ์์ ์
๋ ฅ ๋ฌธ์ฅ ๋ณ๊ฒฝ
|
| 80 |
-
input_sentence = "Here is the sentence you want the model to classify."
|
| 81 |
-
result = nlp(input_sentence)
|
| 82 |
-
|
| 83 |
-
print(result)
|
|
|
|
| 62 |
- Transformers 4.35.0
|
| 63 |
- Pytorch 2.1.0
|
| 64 |
- Datasets 2.14.6
|
| 65 |
+
- Tokenizers 0.14.1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|