mirror of
https://github.com/storytold/artcraft.git
synced 2026-11-06 02:00:46 +00:00
final touches, take out debug
This commit is contained in:
1 parent
91376a804a
commit
5986807cbb
5 files changed
+12
-20
No files matched your search
@@ -20,7 +20,7 @@ export default function VideoStyleTransfer(props:{
|
||||
inferenceJobsByCategory: Map<FrontendInferenceJobType, Array<InferenceJob>>;
|
||||
sessionWrapper: SessionWrapper;
|
||||
}){
|
||||
const debug = true;
|
||||
const debug = false;
|
||||
const {t} = useLocalize("VideoStyleTransfer");
|
||||
const { NO_FILE } = states;
|
||||
const [pageState, dispatchPageState] = useReducer(reducer, {
|
||||
|
||||
+3
-3
@@ -1,4 +1,4 @@
|
||||
type VSTPreset =
|
||||
type CNPreset =
|
||||
'custom'|
|
||||
'closeup'|
|
||||
'halfbody'|
|
||||
@@ -7,7 +7,7 @@ type VSTPreset =
|
||||
'typog';
|
||||
|
||||
const defaultPreset = {
|
||||
cnCanny: 0.7,
|
||||
cnCanny: 0,
|
||||
cnDepth: 0.7,
|
||||
cnLineArtAnime: 0.7,
|
||||
cnLineArtRealistic: 0.7,
|
||||
@@ -81,7 +81,7 @@ const typogPreset = {
|
||||
}
|
||||
|
||||
export type {
|
||||
VSTPreset
|
||||
CNPreset
|
||||
}
|
||||
export {
|
||||
defaultPreset,
|
||||
+2
-10
@@ -1,3 +1,4 @@
|
||||
import { defaultPreset as defaultCN } from "./cnPresets";
|
||||
export {initialValues, hiddenValues};
|
||||
const initialValues = {
|
||||
//files Settings
|
||||
@@ -25,16 +26,7 @@ const initialValues = {
|
||||
visibility: "private",
|
||||
|
||||
//Control Net
|
||||
cnCanny: 0.7,
|
||||
cnDepth: 0.7,
|
||||
cnLineArtAnime: 0.7,
|
||||
cnLineArtRealistic: 0.7,
|
||||
cnLipsStrength: 0,
|
||||
cnOpenPose: 0.7,
|
||||
cnPipeFace: 0.7,
|
||||
cnSparseScribble: 0.7,
|
||||
cnSoftEdge: 0.7,
|
||||
cnRegularSteps: 30,
|
||||
...defaultCN
|
||||
};
|
||||
|
||||
const hiddenValues = {
|
||||
|
||||
+2
-2
@@ -62,11 +62,11 @@ export function mapRequest(vstValues: VSTType){
|
||||
"$.8.inputs.text":
|
||||
hiddenValues.negPrompt+ vstValues.negPrompt,
|
||||
|
||||
"$.800.inputs.Value": vstValues.cnCanny,
|
||||
"$.800.inputs.Value": 0, //vstValues.cnCanny,
|
||||
"$.772.inputs.Value": vstValues.cnDepth,
|
||||
"$.797.inputs.Value": vstValues.cnLineArtAnime,
|
||||
"$.796.inputs.Value": vstValues.cnLineArtRealistic,
|
||||
"$.1636.inputs.Value": vstValues.cnLipsStrength,
|
||||
"$.1636.inputs.Value": 0, //vstValues.cnLipsStrength,
|
||||
"$.771.inputs.Value": vstValues.cnOpenPose,
|
||||
"$.403.inputs.Value": vstValues.cnSparseScribble,
|
||||
"$.1398.inputs.Value": vstValues.cnSoftEdge,
|
||||
|
||||
+4
-4
@@ -18,14 +18,14 @@ import {
|
||||
} from 'components/common';
|
||||
import { VSTType } from './helpers';
|
||||
import {
|
||||
VSTPreset,
|
||||
CNPreset,
|
||||
closeupPreset,
|
||||
halfbodyPreset,
|
||||
fullbodyPreset,
|
||||
landscapePreset,
|
||||
typogPreset,
|
||||
defaultPreset,
|
||||
} from './vstPresets';
|
||||
} from './cnPresets';
|
||||
|
||||
|
||||
export default function SectionAdvanceOptions({
|
||||
@@ -36,8 +36,8 @@ export default function SectionAdvanceOptions({
|
||||
onChange: (val:{[key: string]: number|string|boolean|undefined})=>void
|
||||
}){
|
||||
|
||||
const [preset, pickPreset] = useState<VSTPreset>('custom')
|
||||
function handlePreset(newPreset: VSTPreset){
|
||||
const [preset, pickPreset] = useState<CNPreset>('custom')
|
||||
function handlePreset(newPreset: CNPreset){
|
||||
switch (newPreset){
|
||||
case 'closeup':
|
||||
handleOnChange(closeupPreset);
|
||||
|
||||
Reference in new issue
Block a user