diff --git a/REAL-Video-Enhancer.py b/REAL-Video-Enhancer.py index 8e4541bb..0010cc0f 100644 --- a/REAL-Video-Enhancer.py +++ b/REAL-Video-Enhancer.py @@ -283,7 +283,7 @@ def updateVideoGUIDetails(self): self.interpolationContainer.setVisible( isInterpolate ) - self.sloMoModeContainer.setVisible( + self.interpolateContainer_2.setVisible( isInterpolate ) # set interpolation container visible if interpolate model is not none @@ -337,6 +337,8 @@ def startRender(self): ), benchmarkMode=self.benchmarkModeCheckBox.isChecked(), sloMoMode=self.sloMoModeCheckBox.isChecked(), + dyanmicScaleOpticalFlow=self.dynamicScaledOpticalFlowCheckBox.isChecked(), + ensemble=self.ensembleCheckBox.isChecked(), ) def disableProcessPage(self): diff --git a/src/ui/ProcessTab.py b/src/ui/ProcessTab.py index 87dc0188..00caad36 100644 --- a/src/ui/ProcessTab.py +++ b/src/ui/ProcessTab.py @@ -119,7 +119,7 @@ def QConnect(self): # set tile size visible to false by default self.parent.tileSizeContainer.setVisible(False) #set slo mo container visable to false by default - self.parent.sloMoModeContainer.setVisible(False) + self.parent.interpolateContainer_2.setVisible(False) # connect up tilesize container visiable self.parent.tilingCheckBox.stateChanged.connect(self.onTilingSwitch) @@ -199,6 +199,8 @@ def run( interpolateModel: str, benchmarkMode: bool, sloMoMode: bool, + dyanmicScaleOpticalFlow: bool, + ensemble: bool, ): interpolateModels, upscaleModels = self.getModels(backend) if interpolateModel == "None": @@ -225,6 +227,8 @@ def run( """ self.benchmarkMode = benchmarkMode self.sloMoMode = sloMoMode + self.dyanmicScaleOpticalFlow = dyanmicScaleOpticalFlow + self.ensemble = ensemble # get model attributes if interpolateModel: @@ -362,6 +366,14 @@ def renderToPipeThread( command += [ "--slomo_mode", ] + if self.dyanmicScaleOpticalFlow: + command += [ + "--dynamic_scaled_optical_flow", + ] + if self.ensemble: + command += [ + "--ensemble", + ] if self.settings["preview_enabled"] == "True": command += [ diff --git a/testRVEInterface.ui b/testRVEInterface.ui index 7d6a1d07..b4b3fe86 100644 --- a/testRVEInterface.ui +++ b/testRVEInterface.ui @@ -7,7 +7,7 @@ 0 0 987 - 706 + 762 @@ -601,7 +601,7 @@ QScrollBar:horizontal{ - 16000 + 400 16777215 @@ -629,10 +629,28 @@ QScrollBar:horizontal{ + + + 0 + 0 + + + + + 1677215 + 16777215 + + 0 + + + 0 + 0 + + General @@ -644,7 +662,7 @@ QScrollBar:horizontal{ 0 - 10 + 0 0 @@ -655,6 +673,18 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + @@ -671,7 +701,7 @@ QScrollBar:horizontal{ - 15 + 12 @@ -707,6 +737,18 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + @@ -726,7 +768,7 @@ QScrollBar:horizontal{ - 15 + 12 @@ -762,11 +804,23 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + - 15 + 12 @@ -802,11 +856,23 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + - 15 + 12 @@ -842,11 +908,23 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + - 15 + 12 @@ -885,11 +963,23 @@ QScrollBar:horizontal{ true + + 0 + + + 0 + + + 0 + + + 0 + - 15 + 12 @@ -928,21 +1018,142 @@ QScrollBar:horizontal{ + + + + + 16000 + 150 + + + + QWidget{ +background-color:#1f232a; +border-radius:10px; +} + + + + + + + true + + + + 0 + 0 + + + + + 0 + 125 + + + + + 16777215 + 125 + + + + + + + QTextEdit{ +background-color:#343b47; +color:white; +} +QTextEdit:disabled{color:white;} + + + Qt::ScrollBarPolicy::ScrollBarAlwaysOff + + + Qt::ScrollBarPolicy::ScrollBarAlwaysOff + + + QAbstractScrollArea::SizeAdjustPolicy::AdjustToContents + + + QTextEdit::LineWrapMode::NoWrap + + + true + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><meta charset="utf-8" /><style type="text/css"> +p, li { white-space: pre-wrap; } +hr { height: 1px; border-width: 0; } +li.unchecked::marker { content: "\2610"; } +li.checked::marker { content: "\2612"; } +</style></head><body style=" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">FPS:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Resolution:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Frame Count:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Bitrate:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Encoder:</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Container:</span></p></body></html> + + + + + + + + + + Qt::Orientation::Vertical + + + QSizePolicy::Policy::Fixed + + + + 20 + 10 + + + + Advanced - + + + + 0 + 0 + + + + 6 + + + 9 + + + 0 + + + 9 + + + 0 + - 15 + 12 @@ -1004,6 +1215,13 @@ QScrollBar:horizontal{ + + + + Qt::Orientation::Horizontal + + + @@ -1013,6 +1231,41 @@ QScrollBar:horizontal{ + + 0 + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + 15 + true + + + + Upscale Settings + + + + + + + Qt::Orientation::Horizontal + + + @@ -1020,13 +1273,13 @@ QScrollBar:horizontal{ 6 - 0 + 9 0 - 0 + 9 9 @@ -1035,7 +1288,7 @@ QScrollBar:horizontal{ - 15 + 12 @@ -1092,16 +1345,16 @@ QScrollBar:horizontal{ - 0 + 6 - 0 + 9 0 - 0 + 9 0 @@ -1110,7 +1363,7 @@ QScrollBar:horizontal{ - 15 + 12 @@ -1164,87 +1417,238 @@ QScrollBar:horizontal{ - + - Qt::Orientation::Vertical - - - - 20 - 40 - + Qt::Orientation::Horizontal - + - - - - - - - - - 15 - - - - SloMo Mode - - - - - - - Qt::Orientation::Horizontal - - - - 226 - 20 - - - - - - - - - 25 - 25 - - - - <html><head/><body><p>Increase video length instead of framerate when interpolating.</p><p>Audio and Subtitles will not be transfered to output video.</p></body></html> - - - - - - :/icons/icons/info.svg - - - true - - - - - - - - - - - - - - + + + + 0 + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + 15 + true + + + + Interpolate Settings + + + + + + + + + + + 12 + + + + Dynamic Scaled Optical Flow (Pytorch Only) + + + + + + + Qt::Orientation::Horizontal + + + + 226 + 20 + + + + + + + + + 25 + 25 + + + + <html><head/><body><p>Scales optical flow based on the difference between frames.</p><p>Helps with anime interpolation.</p></body></html> + + + + + + :/icons/icons/info.svg + + + true + + + + + + + + + + + + + + + + + + + + + 12 + + + + Ensemble (Pytorch/TensorRT Only) + + + + + + + Qt::Orientation::Horizontal + + + + 226 + 20 + + + + + + + + + 25 + 25 + + + + <html><head/><body><p>Ensembles flow, can produce better results.</p><p>Only compadible with older RIFE models and GMFSS</p></body></html> + + + + + + :/icons/icons/info.svg + + + true + + + + + + + + + + + + + + + + + Qt::Orientation::Horizontal + + + + + + + + + + + 12 + + + + SloMo Mode + + + + + + + Qt::Orientation::Horizontal + + + + 226 + 20 + + + + + + + + + 25 + 25 + + + + <html><head/><body><p>Increase video length instead of framerate when interpolating.</p><p>Audio and Subtitles will not be transfered to output video.</p></body></html> + + + + + + :/icons/icons/info.svg + + + true + + + + + + + + + + + + + + + - + Qt::Orientation::Vertical @@ -1260,108 +1664,14 @@ QScrollBar:horizontal{ - - - - - 16000 - 150 - - - - QWidget{ -background-color:#1f232a; -border-radius:10px; -} - - - - - - - true - - - - 0 - 0 - - - - - 0 - 125 - - - - - 16777215 - 125 - - - - - - - QTextEdit{ -background-color:#343b47; -color:white; -} -QTextEdit:disabled{color:white;} - - - Qt::ScrollBarPolicy::ScrollBarAlwaysOff - - - Qt::ScrollBarPolicy::ScrollBarAlwaysOff - - - QAbstractScrollArea::SizeAdjustPolicy::AdjustToContents - - - QTextEdit::LineWrapMode::NoWrap - - - true - - - <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> -<html><head><meta name="qrichtext" content="1" /><meta charset="utf-8" /><style type="text/css"> -p, li { white-space: pre-wrap; } -hr { height: 1px; border-width: 0; } -li.unchecked::marker { content: "\2610"; } -li.checked::marker { content: "\2612"; } -</style></head><body style=" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;"> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">FPS:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Resolution:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Frame Count:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Bitrate:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Encoder:</span></p> -<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Sans Serif';">Container:</span></p></body></html> - - - - - - - - - - Qt::Orientation::Vertical - - - QSizePolicy::Policy::MinimumExpanding - - - - 20 - 0 - - - - + + + 0 + 0 + + 0 @@ -1512,7 +1822,7 @@ background-color:#343b47 - + 0 0 @@ -1626,7 +1936,7 @@ QLabel{ - + 0 0 @@ -1833,7 +2143,7 @@ QTabWidget::pane { /* The tab widget frame */ 0 0 787 - 622 + 632 @@ -2004,7 +2314,7 @@ QTabWidget::pane { /* The tab widget frame */ - Video Quality + Video &Quality @@ -2836,7 +3146,7 @@ QScrollBar:horizontal{ 0 0 - 755 + 699 332