mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
fix: Remove type from Model type name
This commit is contained in:
parent
7c9a939b47
commit
809ec7163e
@ -7,18 +7,17 @@ import {
|
|||||||
|
|
||||||
import { receivedModels } from 'services/thunks/model';
|
import { receivedModels } from 'services/thunks/model';
|
||||||
|
|
||||||
export type SD1PipelineModelType = (
|
export type SD1PipelineModel = (
|
||||||
| StableDiffusion1ModelCheckpointConfig
|
| StableDiffusion1ModelCheckpointConfig
|
||||||
| StableDiffusion1ModelDiffusersConfig
|
| StableDiffusion1ModelDiffusersConfig
|
||||||
) & {
|
) & {
|
||||||
name: string;
|
name: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const sd1PipelineModelsAdapter =
|
export const sd1PipelineModelsAdapter = createEntityAdapter<SD1PipelineModel>({
|
||||||
createEntityAdapter<SD1PipelineModelType>({
|
selectId: (model) => model.name,
|
||||||
selectId: (model) => model.name,
|
sortComparer: (a, b) => a.name.localeCompare(b.name),
|
||||||
sortComparer: (a, b) => a.name.localeCompare(b.name),
|
});
|
||||||
});
|
|
||||||
|
|
||||||
export const sd1InitialPipelineModelsState =
|
export const sd1InitialPipelineModelsState =
|
||||||
sd1PipelineModelsAdapter.getInitialState();
|
sd1PipelineModelsAdapter.getInitialState();
|
||||||
|
@ -7,18 +7,17 @@ import {
|
|||||||
|
|
||||||
import { receivedModels } from 'services/thunks/model';
|
import { receivedModels } from 'services/thunks/model';
|
||||||
|
|
||||||
export type SD2PipelineModelType = (
|
export type SD2PipelineModel = (
|
||||||
| StableDiffusion2ModelCheckpointConfig
|
| StableDiffusion2ModelCheckpointConfig
|
||||||
| StableDiffusion2ModelDiffusersConfig
|
| StableDiffusion2ModelDiffusersConfig
|
||||||
) & {
|
) & {
|
||||||
name: string;
|
name: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const sd2PipelineModelsAdapater =
|
export const sd2PipelineModelsAdapater = createEntityAdapter<SD2PipelineModel>({
|
||||||
createEntityAdapter<SD2PipelineModelType>({
|
selectId: (model) => model.name,
|
||||||
selectId: (model) => model.name,
|
sortComparer: (a, b) => a.name.localeCompare(b.name),
|
||||||
sortComparer: (a, b) => a.name.localeCompare(b.name),
|
});
|
||||||
});
|
|
||||||
|
|
||||||
export const sd2InitialPipelineModelsState =
|
export const sd2InitialPipelineModelsState =
|
||||||
sd2PipelineModelsAdapater.getInitialState();
|
sd2PipelineModelsAdapater.getInitialState();
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { log } from 'app/logging/useLogger';
|
import { log } from 'app/logging/useLogger';
|
||||||
import { createAppAsyncThunk } from 'app/store/storeUtils';
|
import { createAppAsyncThunk } from 'app/store/storeUtils';
|
||||||
import { SD1PipelineModelType } from 'features/system/store/models/sd1PipelineModelSlice';
|
import { SD1PipelineModel } from 'features/system/store/models/sd1PipelineModelSlice';
|
||||||
import { SD2PipelineModelType } from 'features/system/store/models/sd2PipelineModelSlice';
|
import { SD2PipelineModel } from 'features/system/store/models/sd2PipelineModelSlice';
|
||||||
import { reduce, size } from 'lodash-es';
|
import { reduce, size } from 'lodash-es';
|
||||||
import { BaseModelType, ModelType, ModelsService } from 'services/api';
|
import { BaseModelType, ModelType, ModelsService } from 'services/api';
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ export const receivedModels = createAppAsyncThunk(
|
|||||||
modelsAccumulator[modelName] = { ...model, name: modelName };
|
modelsAccumulator[modelName] = { ...model, name: modelName };
|
||||||
return modelsAccumulator;
|
return modelsAccumulator;
|
||||||
},
|
},
|
||||||
{} as Record<string, SD1PipelineModelType>
|
{} as Record<string, SD1PipelineModel>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -42,7 +42,7 @@ export const receivedModels = createAppAsyncThunk(
|
|||||||
modelsAccumulator[modelName] = { ...model, name: modelName };
|
modelsAccumulator[modelName] = { ...model, name: modelName };
|
||||||
return modelsAccumulator;
|
return modelsAccumulator;
|
||||||
},
|
},
|
||||||
{} as Record<string, SD2PipelineModelType>
|
{} as Record<string, SD2PipelineModel>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user