Various fixess and xor
This commit is contained in:
@@ -66,6 +66,15 @@ watch(selectedDatasetCopy, (newvalue) => {
|
||||
if (selectedDatasetCopy && selectedDatasetCopy.defaultMaxIterations !== undefined) {
|
||||
maxIterations.value = selectedDatasetCopy.defaultMaxIterations;
|
||||
}
|
||||
// HiddenLayers
|
||||
hiddenLayers.value = props.hiddenLayers;
|
||||
if (selectedDatasetCopy && selectedDatasetCopy.defaultHiddenLayers !== undefined) {
|
||||
hiddenLayers.value = selectedDatasetCopy.defaultHiddenLayers;
|
||||
}
|
||||
hiddenLayersNeurons.value = props.hiddenLayersNeurons;
|
||||
if (selectedDatasetCopy && selectedDatasetCopy.defaultHiddenLayersNeurons !== undefined) {
|
||||
hiddenLayersNeurons.value = selectedDatasetCopy.defaultHiddenLayersNeurons;
|
||||
}
|
||||
})
|
||||
|
||||
const trainingId = ref<string>('');
|
||||
|
||||
@@ -140,6 +140,10 @@ function perceptronTrainingEnded(data: any) {
|
||||
}
|
||||
|
||||
const activationFunction = ref<string>('');
|
||||
const isRegression = computed(
|
||||
() => props.type === 'multilayer' && activationFunction.value === 'linear',
|
||||
);
|
||||
|
||||
function perceptroninitialization(data: any) {
|
||||
console.log('Perceptron training initialized:', data);
|
||||
if (data.trainingId !== trainingId.value) {
|
||||
@@ -216,7 +220,7 @@ function resetTraining() {
|
||||
<PerceptronDecisionGraph
|
||||
:cleanedDataset="cleanedDataset"
|
||||
:iterations="iterations"
|
||||
:is-regression="activationFunction === 'linear'"
|
||||
:is-regression="isRegression"
|
||||
:activation-function="
|
||||
getActivationFunction(activationFunction)
|
||||
"
|
||||
@@ -225,7 +229,7 @@ function resetTraining() {
|
||||
<div>
|
||||
<PerceptronIterationsErrorsGraph
|
||||
:iterations="iterations"
|
||||
:is-regression="activationFunction === 'linear'"
|
||||
:is-regression="isRegression"
|
||||
v-if="iterations.length > 0"
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -11,6 +11,8 @@ export type Dataset = {
|
||||
defaultLearningRate?: number;
|
||||
defaultMinError?: number;
|
||||
defaultMaxIterations?: number;
|
||||
defaultHiddenLayers?: number;
|
||||
defaultHiddenLayersNeurons?: number;
|
||||
};
|
||||
|
||||
export type DatasetPoint = {
|
||||
|
||||
Reference in New Issue
Block a user