Removes force_outpaint param

This commit is contained in:
psychedelicious 2022-11-24 15:20:28 +11:00 committed by blessedcoolant
parent 52c79fa097
commit 7f1b95fbda
3 changed files with 8 additions and 35 deletions

View File

@ -60,7 +60,6 @@ export const frontendToBackendParameters = (
seed,
seedWeights,
shouldFitToWidthHeight,
shouldForceOutpaint,
shouldGenerateVariations,
shouldRandomizeSeed,
shouldRunESRGAN,
@ -190,8 +189,8 @@ export const frontendToBackendParameters = (
generationParameters.seam_strength = seamStrength;
generationParameters.seam_steps = seamSteps;
generationParameters.tile_size = tileSize;
generationParameters.force_outpaint = shouldForceOutpaint;
generationParameters.infill_method = infillMethod;
generationParameters.force_outpaint = false;
}
if (shouldGenerateVariations) {

View File

@ -1,22 +1,20 @@
import { Box, Flex } from '@chakra-ui/react';
import { Flex } from '@chakra-ui/react';
import { createSelector } from '@reduxjs/toolkit';
import { useAppDispatch, useAppSelector } from 'app/store';
import IAISelect from 'common/components/IAISelect';
import IAISlider from 'common/components/IAISlider';
import IAISwitch from 'common/components/IAISwitch';
import { optionsSelector } from 'features/options/store/optionsSelectors';
import {
setSeamSize,
setSeamBlur,
setSeamStrength,
setSeamSteps,
setTileSize,
setShouldForceOutpaint,
setInfillMethod,
setSeamBlur,
setSeamSize,
setSeamSteps,
setSeamStrength,
setTileSize,
} from 'features/options/store/optionsSlice';
import { systemSelector } from 'features/system/store/systemSelectors';
import InpaintReplace from './InpaintReplace';
import _ from 'lodash';
import InpaintReplace from './InpaintReplace';
const selector = createSelector(
[optionsSelector, systemSelector],
@ -27,7 +25,6 @@ const selector = createSelector(
seamStrength,
seamSteps,
tileSize,
shouldForceOutpaint,
infillMethod,
} = options;
@ -39,7 +36,6 @@ const selector = createSelector(
seamStrength,
seamSteps,
tileSize,
shouldForceOutpaint,
infillMethod,
availableInfillMethods,
};
@ -59,7 +55,6 @@ const CompositionOptions = () => {
seamStrength,
seamSteps,
tileSize,
shouldForceOutpaint,
infillMethod,
availableInfillMethods,
} = useAppSelector(selector);
@ -134,13 +129,6 @@ const CompositionOptions = () => {
withSliderMarks
withReset
/>
<IAISwitch
label={'Force Outpaint'}
isChecked={shouldForceOutpaint}
onChange={(e) => {
dispatch(setShouldForceOutpaint(e.target.checked));
}}
/>
<IAISelect
label="Infill Method"
value={infillMethod}
@ -172,11 +160,3 @@ const CompositionOptions = () => {
};
export default CompositionOptions;
export const OutpaintingHeader = () => {
return (
<Box flex="1" textAlign="left">
Outpainting Composition
</Box>
);
};

View File

@ -37,7 +37,6 @@ export interface OptionsState {
seed: number;
seedWeights: string;
shouldFitToWidthHeight: boolean;
shouldForceOutpaint: boolean;
shouldGenerateVariations: boolean;
shouldHoldOptionsPanelOpen: boolean;
shouldLoopback: boolean;
@ -84,7 +83,6 @@ const initialOptionsState: OptionsState = {
seed: 0,
seedWeights: '',
shouldFitToWidthHeight: true,
shouldForceOutpaint: false,
shouldGenerateVariations: false,
shouldHoldOptionsPanelOpen: false,
shouldLoopback: false,
@ -395,9 +393,6 @@ export const optionsSlice = createSlice({
setTileSize: (state, action: PayloadAction<number>) => {
state.tileSize = action.payload;
},
setShouldForceOutpaint: (state, action: PayloadAction<boolean>) => {
state.shouldForceOutpaint = action.payload;
},
setInfillMethod: (state, action: PayloadAction<string>) => {
state.infillMethod = action.payload;
},
@ -438,7 +433,6 @@ export const {
setSeed,
setSeedWeights,
setShouldFitToWidthHeight,
setShouldForceOutpaint,
setShouldGenerateVariations,
setShouldHoldOptionsPanelOpen,
setShouldLoopback,