mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-04-27 09:07:41 +03:00
Improve model train button
This commit is contained in:
parent
99885b4bdc
commit
af5f3e5f84
@ -3,7 +3,8 @@
|
||||
"deleteClassificationAttempts": "Delete Classification Images",
|
||||
"renameCategory": "Rename Class",
|
||||
"deleteCategory": "Delete Class",
|
||||
"deleteImages": "Delete Images"
|
||||
"deleteImages": "Delete Images",
|
||||
"trainModel": "Train Model"
|
||||
},
|
||||
"toast": {
|
||||
"success": {
|
||||
|
||||
@ -50,6 +50,7 @@ import { ModelState } from "@/types/ws";
|
||||
import ActivityIndicator from "@/components/indicators/activity-indicator";
|
||||
import { useNavigate } from "react-router-dom";
|
||||
import { IoMdArrowRoundBack } from "react-icons/io";
|
||||
import { MdAutoFixHigh } from "react-icons/md";
|
||||
|
||||
type ModelTrainingViewProps = {
|
||||
model: CustomClassificationModelConfig;
|
||||
@ -345,8 +346,12 @@ export default function ModelTrainingView({ model }: ModelTrainingViewProps) {
|
||||
onClick={trainModel}
|
||||
disabled={modelState != "complete"}
|
||||
>
|
||||
Train Model
|
||||
{modelState == "training" && <ActivityIndicator size={20} />}
|
||||
{modelState == "training" ? (
|
||||
<ActivityIndicator size={20} />
|
||||
) : (
|
||||
<MdAutoFixHigh />
|
||||
)}
|
||||
{t("button.trainModel")}
|
||||
</Button>
|
||||
)}
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user