Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • jvet/VVCSoftware_VTM
  • chenhuanbang/VVCSoftware_VTM
  • ezhizng/VVCSoftware_VTM
  • XZheng/VVCSoftware_VTM
  • YanZhang/VVCSoftware_VTM
  • xiaozhongxu/VVCSoftware_VTM
  • bossen/VVCSoftware_VTM
  • XiangLi/VVCSoftware_VTM
  • s.iwamura/VVCSoftware_VTM
  • yuling.hsiao/VVCSoftware_VTM
  • ccc2384823/VVCSoftware_VTM
  • yuchisu/VVCSoftware_VTM
  • schwarz/VVCSoftware_VTM
  • philippe.hanhart/VVCSoftware_VTM
  • nanh/VVCSoftware_VTM
  • guillaume.laroche/VVCSoftware_VTM
  • Kenneth/VVCSoftware_VTM
  • jonatan/VVCSoftware_VTM
  • Alexey/VVCSoftware_VTM
  • saintspear/VVCSoftware_VTM
  • xinzhao/VVCSoftware_VTM
  • Seungsoo/VVCSoftware_VTM
  • jamesxxiu/VVCSoftware_VTM
  • leolzhao/VVCSoftware_VTM
  • ywchen/VVCSoftware_VTM
  • kevin625/VVCSoftware_VTM
  • Zhang/VVCSoftware_VTM
  • zhangkai/VVCSoftware_VTM
  • YCSun/VVCSoftware_VTM
  • ksuehring/VVCSoftware_VTM
  • AbeKiyo/VVCSoftware_VTM
  • naeri.park/VVCSoftware_VTM
  • ling/VVCSoftware_VTM
  • aikiho/VVCSoftware_VTM
  • JangwonChoi/VVCSoftware_VTM
  • Shelly/VVCSoftware_VTM
  • blaeser/VVCSoftware_VTM
  • crhelmrich/VVCSoftware_VTM
  • keydel/VVCSoftware_VTM
  • adam_wieckowski/VVCSoftware_VTM
  • hashimry/VVCSoftware_VTM
  • yimingli/VVCSoftware_VTM
  • zhipin/VVCSoftware_VTM
  • chernyak/VVCSoftware_VTM
  • jvet-l-ahg-14/VVCSoftware_VTM
  • sauer/VVCSoftware_VTM
  • fbarbier/VVCSoftware_VTM
  • misrak/VVCSoftware_VTM
  • ikai/VVCSoftware_VTM
  • tlu/VVCSoftware_VTM
  • Yasugi/VVCSoftware_VTM
  • peterchuang/VVCSoftware_VTM
  • wanght99/VVCSoftware_VTM
  • yuhan/VVCSoftware_VTM
  • hongbin/VVCSoftware_VTM
  • jiahaoli/VVCSoftware_VTM
  • cfd/VVCSoftware_VTM
  • ruoyangyu/VVCSoftware_VTM
  • chujoh/VVCSoftware_VTM
  • lijingya/VVCSoftware_VTM
  • hinz/VVCSoftware_VTM
  • tamse.anish/VVCSoftware_VTM
  • mcoban/VVCSoftware_VTM
  • george/VVCSoftware_VTM
  • jeeva.raj/VVCSoftware_VTM
  • antoine/VVCSoftware_VTM
  • moonmo.koo/VVCSoftware_VTM
  • deluxan/VVCSoftware_VTM
  • bheng/VVCSoftware_VTM
  • lzz8246/VVCSoftware_VTM
  • delagrangep/VVCSoftware_VTM
  • jiechen/VVCSoftware_VTM
  • hendry197/VVCSoftware_VTM
  • LGE_VCC/VVCSoftware_VTM
  • asegall/VVCSoftware_VTM
  • pbcowan/VVCSoftware_VTM
  • forayr/VVCSoftware_VTM
  • JT/VVCSoftware_VTM
  • Zhou/VVCSoftware_VTM
  • yjpiao/VVCSoftware_VTM
  • fabrice.leleannec/VVCSoftware_VTM
  • tpoirier/VVCSoftware_VTM
  • PoHan.Lin/VVCSoftware_VTM
  • jzxu/VVCSoftware_VTM
  • junghak.nam/VVCSoftware_VTM
  • guichunli/VVCSoftware_VTM
  • xianglinwang/VVCSoftware_VTM
  • chunchic/VVCSoftware_VTM
  • chrisr12/VVCSoftware_VTM
  • ks_kashyap/VVCSoftware_VTM
  • minhua/VVCSoftware_VTM
  • Sheng-Yen.Lin/VVCSoftware_VTM
  • hegilmez/VVCSoftware_VTM
  • swongah/VVCSoftware_VTM
  • merkle/VVCSoftware_VTM
  • sunyucheng/VVCSoftware_VTM
  • kirchhoffer/VVCSoftware_VTM
  • vdrugeon/VVCSoftware_VTM
  • jennylai/VVCSoftware_VTM
  • rickxu/VVCSoftware_VTM
  • seuhong/VVCSoftware_VTM
  • chollmann/VVCSoftware_VTM
  • jvet-n-ce8-public/VVCSoftware_VTM
  • martin.m.pettersson/VVCSoftware_VTM
  • siekmann/VVCSoftware_VTM
  • aramasub/VVCSoftware_VTM
  • zhiyilin/VVCSoftware_VTM
  • EricLin/VVCSoftware_VTM
  • mengwang/VVCSoftware_VTM
  • m.sarwer/VVCSoftware_VTM
  • agnesedong/VVCSoftware_VTM
  • geonjungko/VVCSoftware_VTM
  • bray/VVCSoftware_VTM
  • yhchao/VVCSoftware_VTM
  • Zhu/VVCSoftware_VTM
  • ykato/VVCSoftware_VTM
  • ZhipinDeng/VVCSoftware_VTM
  • jasonjung/VVCSoftware_VTM
  • hanhuang/VVCSoftware_VTM
  • seregin/VVCSoftware_VTM
  • wchen1014/VVCSoftware_VTM
  • Auyeung/VVCSoftware_VTM
  • Morris/VVCSoftware_VTM
  • lphamvan/VVCSoftware_VTM
  • dmehlem/VVCSoftware_VTM
  • shih-ta.hsiang/VVCSoftware_VTM
  • ysanchez/VVCSoftware_VTM
  • baegn74/VVCSoftware_VTM
  • kazui/VVCSoftware_VTM
  • yuwenhe_vvc/VVCSoftware_VTM
  • rickard/VVCSoftware_VTM
  • wangyang.cs/VVCSoftware_VTM
  • xwmeng/VVCSoftware_VTM
  • takeshi.tsukuba/VVCSoftware_VTM
  • yixindu/VVCSoftware_VTM
  • baixiu.wz/VVCSoftware_VTM
  • hm.jang/VVCSoftware_VTM
  • Ted/VVCSoftware_VTM
  • nguyen/VVCSoftware_VTM
  • chaohsiu/VVCSoftware_VTM
  • francoise/VVCSoftware_VTM
  • Yin/VVCSoftware_VTM
  • Morigami/VVCSoftware_VTM
  • sagar.kotecha/VVCSoftware_VTM
  • hwsun/VVCSoftware_VTM
  • pierrick.bouvier/VVCSoftware_VTM
  • XiangMa/VVCSoftware_VTM
  • LouiseLee/VVCSoftware_VTM
  • chenps/VVCSoftware_VTM
  • karls/VVCSoftware_VTM
  • biaowang/VVCSoftware_VTM
  • hangao/VVCSoftware_VTM
  • Jin/VVCSoftware_VTM
  • analci/VVCSoftware_VTM
  • KuiFan/VVCSoftware_VTM
  • hobingzhang/VVCSoftware_VTM
  • audrey.turquin/VVCSoftware_VTM
  • rlliao/VVCSoftware_VTM
  • winken/VVCSoftware_VTM
  • hallapur/VVCSoftware_VTM
  • T.Hashimoto/VVCSoftware_VTM
  • AnandMeher/VVCSoftware_VTM
  • semihese/VVCSoftware_VTM
  • ouedraogo/VVCSoftware_VTM
  • arthurcerveira/VVCSoftware_VTM
  • sunmi.yoo/VVCSoftware_VTM
  • Cynthia/VVCSoftware_VTM
  • yang/VVCSoftware_VTM
  • yuyoon/VVCSoftware_VTM
  • jslee/VVCSoftware_VTM
  • weimin.zeng/VVCSoftware_VTM
  • edrthomas/VVCSoftware_VTM
  • Mitsuru.Katsumata/VVCSoftware_VTM
  • adybrowne/VVCSoftware_VTM
  • jack.enhorn/VVCSoftware_VTM
  • Palanivel/VVCSoftware_VTM
  • olena.chubach/VVCSoftware_VTM
  • juvenalluo/VVCSoftware_VTM
  • yylee/VVCSoftware_VTM
  • bross/VVCSoftware_VTM
  • jvet-ahg-nnvc/VVCSoftware_VTM
  • jacob/VVCSoftware_VTM
  • dmytro.rusanovskyy/VVCSoftware_VTM
  • karamnaser/VVCSoftware_VTM
  • milos.radosavljevic/VVCSoftware_VTM
  • Keming/VVCSoftware_VTM
  • pj/VVCSoftware_VTM
  • cwkuo/VVCSoftware_VTM
  • BD/VVCSoftware_VTM
  • bartnik/VVCSoftware_VTM
  • Fangjun.Pu/VVCSoftware_VTM
  • nikolay.shostak/VVCSoftware_VTM
  • kirill.suverov/VVCSoftware_VTM
  • Xile_Zhou/VVCSoftware_VTM
  • ksuehring/vvc-software-vtm-nnvc
  • guether/VVCSoftware_VTM
  • salmonc/VVCSoftware_VTM
  • eeehey/VVCSoftware_VTM
  • marie-pierre.gallasso/VVCSoftware_VTM
  • jvet-ahg-fgt/VTM
  • liaojq/VVCSoftware_VTM
  • axel.ricard/VVCSoftware_VTM
  • XiangLi/nnvc
  • sw.xie/VVCSoftware_VTM
  • jeeva.raj/vvc-software-vtm-tu-c
  • XiangLi/tu-c
  • msantamaria/nnvc
  • cjj490168650/VVCSoftware_VTM
  • Yun_li/VVCSoftware_VTM
  • Zhengang/vvc-software-vtm
  • lvzhuoyi/vvc-software-vtm-nnvc
  • Kenneth/vvc-software-vtm-nn
  • biatekt/vvc-software-vtm
  • jvet-ahg-gcc/VVCSoftware_VTM
  • JINGYING/VVCSoftware_VTM
  • furban/VVCSoftware_VTM
  • yanning/VVCSoftware_VTM
  • zhuochen/VVCSoftware_VTM
  • Kaifa/VVCSoftware_VTM_AJ0048
  • yueli/VVCSoftware_VTM
  • tokumo/VVCSoftware_VTM
221 results
Show changes
Commits on Source (5)
...@@ -5942,6 +5942,18 @@ Specifies sii_num_units_in_shutter_interval for single entry.If multiple entries ...@@ -5942,6 +5942,18 @@ Specifies sii_num_units_in_shutter_interval for single entry.If multiple entries
\Default{0} & \Default{0} &
Specifies the bottom offset of spatial extrapolation for the \emph{i}-th neural network post-filter. Specifies the bottom offset of spatial extrapolation for the \emph{i}-th neural network post-filter.
\\ \\
\Option{SEINNPFCAapplicationPurposeTagUriPresentFlag\emph{i}} &
\Default{false} &
Specifies the nnpfc_application_purpose_tag_uri_present_flag syntax element for the \emph{i}-th neural network post-filter.
\par
When true (non-zero) specifies the presence of the nnpfc_application_purpose_tag_uri syntax element in the NNPFC SEI message.
\par
When false specifies the absence of the nnpfc_application_purpose_tag_uri syntax element in the NNPFC SEI message.
\\
\Option{SEINNPFCApplicationPurposeTagUri\emph{i}} &
\Default{""} &
specifies a tag URI with syntax and semantics as specified in IETF RFC 4151 identifying the application determined purpose of the NNPF, when nnpfc_purpose is equal to 0 of the \emph{i}-th neural network post-filter.
\\
\Option{SEINNPFCInputPicOutputFlag\emph{i}} & \Option{SEINNPFCInputPicOutputFlag\emph{i}} &
\Default{false} & \Default{false} &
Indicates whether the i-th neural network post filter generates a corresponding output picture for the i-th input picture. Indicates whether the i-th neural network post filter generates a corresponding output picture for the i-th input picture.
......
...@@ -1281,6 +1281,13 @@ void EncApp::xInitLibCfg( int layerIdx ) ...@@ -1281,6 +1281,13 @@ void EncApp::xInitLibCfg( int layerIdx )
m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationRightOffset (m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[i], i); m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationRightOffset (m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[i], i);
m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset (m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[i], i); m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset (m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[i], i);
m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[i], i); m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[i], i);
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag( m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[i], i);
if (m_cEncLib.getNNPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag(i))
{
m_cEncLib.setNNPostFilterSEICharacteristicsSpatialExrapolationPrompt( m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[i], i);
}
#endif
} }
#endif #endif
m_cEncLib.setNNPostFilterSEICharacteristicsAbsentInputPicZeroFlag (m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[i], i); m_cEncLib.setNNPostFilterSEICharacteristicsAbsentInputPicZeroFlag (m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[i], i);
......
...@@ -2077,6 +2077,14 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) ...@@ -2077,6 +2077,14 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] )
std::ostringstream spatialExtrapolationBottomOffset; std::ostringstream spatialExtrapolationBottomOffset;
spatialExtrapolationBottomOffset << "SEINNPFCSpatialExtrapolationLeftOffset" << i; spatialExtrapolationBottomOffset << "SEINNPFCSpatialExtrapolationLeftOffset" << i;
opts.addOptions()(spatialExtrapolationBottomOffset.str(), m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[i], 0, "Bottom offset of spatial extrapolation"); opts.addOptions()(spatialExtrapolationBottomOffset.str(), m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[i], 0, "Bottom offset of spatial extrapolation");
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
std::ostringstream spatialextrapolationPromptPresentFlag;
spatialextrapolationPromptPresentFlag << "SEINNPFCSpatialExtrapolationPromptPresentFlag" << i;
opts.addOptions()(spatialextrapolationPromptPresentFlag.str(), m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[i], false, "equal to 1 specifies that nnpfc_prompt syntax element is present and nnpfc_alignment_zero_bit_c syntax element may be present. nnpfc_spatial_extrapolation_prompt_present_flag equal to 0 specifies that nnpfc_prompt syntax element and nnpfc_alignment_zero_bit_c syntax element are not present.");
std::ostringstream spatialextrapolationPrompt;
spatialextrapolationPrompt << "SEINNPFCSpatialExtrapolationPrompt" << i;
opts.addOptions()(spatialextrapolationPrompt.str(), m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[i], std::string(""), "specifies the text string prompt used for generating the contents of the spatial extrapolation image area.");
#endif
#endif #endif
std::ostringstream InputPicOutputFlag; std::ostringstream InputPicOutputFlag;
InputPicOutputFlag << "SEINNPFCInputPicOutputFlag" << i; InputPicOutputFlag << "SEINNPFCInputPicOutputFlag" << i;
......
...@@ -829,6 +829,10 @@ protected: ...@@ -829,6 +829,10 @@ protected:
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[MAX_NUM_NN_POST_FILTERS];
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[MAX_NUM_NN_POST_FILTERS];
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[MAX_NUM_NN_POST_FILTERS];
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
bool m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[MAX_NUM_NN_POST_FILTERS];
std::string m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[MAX_NUM_NN_POST_FILTERS];
#endif
#endif #endif
std::vector<bool> m_nnPostFilterSEICharacteristicsInputPicOutputFlag[MAX_NUM_NN_POST_FILTERS]; std::vector<bool> m_nnPostFilterSEICharacteristicsInputPicOutputFlag[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[MAX_NUM_NN_POST_FILTERS]; bool m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[MAX_NUM_NN_POST_FILTERS];
......
...@@ -1027,6 +1027,10 @@ SEINeuralNetworkPostFilterCharacteristics::SEINeuralNetworkPostFilterCharacteris ...@@ -1027,6 +1027,10 @@ SEINeuralNetworkPostFilterCharacteristics::SEINeuralNetworkPostFilterCharacteris
m_spatialExtrapolationRightOffset = sei.m_spatialExtrapolationRightOffset; m_spatialExtrapolationRightOffset = sei.m_spatialExtrapolationRightOffset;
m_spatialExtrapolationTopOffset = sei.m_spatialExtrapolationTopOffset; m_spatialExtrapolationTopOffset = sei.m_spatialExtrapolationTopOffset;
m_spatialExtrapolationBottomOffset = sei.m_spatialExtrapolationBottomOffset; m_spatialExtrapolationBottomOffset = sei.m_spatialExtrapolationBottomOffset;
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
m_spatialExtrapolationPromptPresentFlag = sei.m_spatialExtrapolationPromptPresentFlag;
m_prompt = sei.m_prompt;
#endif
#endif #endif
m_inputPicOutputFlag = sei.m_inputPicOutputFlag; m_inputPicOutputFlag = sei.m_inputPicOutputFlag;
} }
...@@ -1095,6 +1099,10 @@ bool SEINeuralNetworkPostFilterCharacteristics::operator == (const SEINeuralNetw ...@@ -1095,6 +1099,10 @@ bool SEINeuralNetworkPostFilterCharacteristics::operator == (const SEINeuralNetw
m_spatialExtrapolationRightOffset == sei.m_spatialExtrapolationRightOffset && m_spatialExtrapolationRightOffset == sei.m_spatialExtrapolationRightOffset &&
m_spatialExtrapolationTopOffset == sei.m_spatialExtrapolationTopOffset && m_spatialExtrapolationTopOffset == sei.m_spatialExtrapolationTopOffset &&
m_spatialExtrapolationBottomOffset == sei.m_spatialExtrapolationBottomOffset && m_spatialExtrapolationBottomOffset == sei.m_spatialExtrapolationBottomOffset &&
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
m_spatialExtrapolationPromptPresentFlag == sei.m_spatialExtrapolationPromptPresentFlag &&
m_prompt == sei.m_prompt &&
#endif
#endif #endif
m_inputPicOutputFlag == sei.m_inputPicOutputFlag && m_inputPicOutputFlag == sei.m_inputPicOutputFlag &&
m_payloadLength == sei.m_payloadLength; m_payloadLength == sei.m_payloadLength;
......
...@@ -1440,6 +1440,10 @@ public: ...@@ -1440,6 +1440,10 @@ public:
, m_spatialExtrapolationRightOffset(0) , m_spatialExtrapolationRightOffset(0)
, m_spatialExtrapolationTopOffset(0) , m_spatialExtrapolationTopOffset(0)
, m_spatialExtrapolationBottomOffset(0) , m_spatialExtrapolationBottomOffset(0)
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
, m_spatialExtrapolationPromptPresentFlag(false)
, m_prompt("")
#endif
#endif #endif
, m_absentInputPicZeroFlag(false) , m_absentInputPicZeroFlag(false)
, m_numInpPicsInOutputTensor(0) , m_numInpPicsInOutputTensor(0)
...@@ -1527,6 +1531,10 @@ public: ...@@ -1527,6 +1531,10 @@ public:
int32_t m_spatialExtrapolationRightOffset; int32_t m_spatialExtrapolationRightOffset;
int32_t m_spatialExtrapolationTopOffset; int32_t m_spatialExtrapolationTopOffset;
int32_t m_spatialExtrapolationBottomOffset; int32_t m_spatialExtrapolationBottomOffset;
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
bool m_spatialExtrapolationPromptPresentFlag;
std::string m_prompt;
#endif
#endif #endif
std::vector<bool> m_inputPicOutputFlag; std::vector<bool> m_inputPicOutputFlag;
bool m_absentInputPicZeroFlag; bool m_absentInputPicZeroFlag;
......
...@@ -186,6 +186,15 @@ void SEINeuralNetworkPostFiltering::filterPictures(PicList& picList) ...@@ -186,6 +186,15 @@ void SEINeuralNetworkPostFiltering::filterPictures(PicList& picList)
for (auto sei : currCodedPic->m_nnpfcActivated) for (auto sei : currCodedPic->m_nnpfcActivated)
{ {
auto currNnpfc = (SEINeuralNetworkPostFilterCharacteristics*) sei; auto currNnpfc = (SEINeuralNetworkPostFilterCharacteristics*) sei;
#if JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION
if ((currNnpfc->m_purpose & NNPC_PurposeType::SPATIAL_EXTRAPOLATION) != 0)
{
currNnpfc->m_overlap = 0;
currNnpfc->m_constantPatchSizeFlag = 1;
currNnpfc->m_patchWidthMinus1 = croppedWidth - 1;
currNnpfc->m_patchHeightMinus1 = croppedHeight - 1;
}
#endif
checkInputPics(currCodedPic, currNnpfc, sourceWidth, sourceHeight, croppedWidth, croppedHeight); checkInputPics(currCodedPic, currNnpfc, sourceWidth, sourceHeight, croppedWidth, croppedHeight);
} }
......
...@@ -70,6 +70,10 @@ ...@@ -70,6 +70,10 @@
#define JVET_AI0153_OMI_SEI 1 // JVET-AI0153: OMI-SEI Implementation as JVET-AH0346 #define JVET_AI0153_OMI_SEI 1 // JVET-AI0153: OMI-SEI Implementation as JVET-AH0346
#define JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1 1 //JVET-AI0061 proposal 1: signal a NNPFC prompt for spatial extrapolation
#define JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION 1 // JVET AI0061-Proposal2: Ensure spatial extrapolation works correctly (Option 1)
//########### place macros to be be kept below this line ############### //########### place macros to be be kept below this line ###############
#define GDR_ENABLED 1 #define GDR_ENABLED 1
......
...@@ -3188,6 +3188,21 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC ...@@ -3188,6 +3188,21 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
sei.m_spatialExtrapolationTopOffset = value; sei.m_spatialExtrapolationTopOffset = value;
sei_read_svlc(pDecodedMessageOutputStream, value, "nnpfc_spatial_extrapolation_bottom_offset"); sei_read_svlc(pDecodedMessageOutputStream, value, "nnpfc_spatial_extrapolation_bottom_offset");
sei.m_spatialExtrapolationBottomOffset = value; sei.m_spatialExtrapolationBottomOffset = value;
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
sei_read_flag(pDecodedMessageOutputStream, val, "nnpfc_spatial_extrapolation_prompt_present_flag");
sei.m_spatialExtrapolationPromptPresentFlag = val;
if (sei.m_spatialExtrapolationPromptPresentFlag)
{
std::string valp;
while (!isByteAligned())
{
sei_read_flag(pDecodedMessageOutputStream, val, "nnpfc_alignment_zero_bit_c");
CHECK(val != 0, "nnpfc_alignment_zero_bit_c not equal to zero");
}
sei_read_string(pDecodedMessageOutputStream, valp, "nnpfc_prompt");
sei.m_prompt = valp;
}
#endif
} }
#endif #endif
...@@ -3306,28 +3321,35 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC ...@@ -3306,28 +3321,35 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
CHECK(sei.m_chromaSampleLocTypeFrame > Chroma420LocType::UNSPECIFIED, "The value of nnpfc_chroma_sample_loc_type_frame shall be in the range of 0 to 6, inclusive"); CHECK(sei.m_chromaSampleLocTypeFrame > Chroma420LocType::UNSPECIFIED, "The value of nnpfc_chroma_sample_loc_type_frame shall be in the range of 0 to 6, inclusive");
} }
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_overlap"); #if JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION
sei.m_overlap = val; if((sei.m_purpose & NNPC_PurposeType::SPATIAL_EXTRAPOLATION) == 0)
{
#endif
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_overlap");
sei.m_overlap = val;
sei_read_flag(pDecodedMessageOutputStream, val, "nnpfc_constant_patch_size_flag"); sei_read_flag(pDecodedMessageOutputStream, val, "nnpfc_constant_patch_size_flag");
sei.m_constantPatchSizeFlag = val; sei.m_constantPatchSizeFlag = val;
if (sei.m_constantPatchSizeFlag) if (sei.m_constantPatchSizeFlag)
{ {
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_patch_width_minus1"); sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_patch_width_minus1");
sei.m_patchWidthMinus1 = val; sei.m_patchWidthMinus1 = val;
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_patch_height_minus1"); sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_patch_height_minus1");
sei.m_patchHeightMinus1 = val; sei.m_patchHeightMinus1 = val;
} }
else else
{ {
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_extended_patch_width_cd_delta_minus1"); sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_extended_patch_width_cd_delta_minus1");
sei.m_extendedPatchWidthCdDeltaMinus1 = val; sei.m_extendedPatchWidthCdDeltaMinus1 = val;
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_extended_patch_height_cd_delta_minus1"); sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_extended_patch_height_cd_delta_minus1");
sei.m_extendedPatchHeightCdDeltaMinus1 = val; sei.m_extendedPatchHeightCdDeltaMinus1 = val;
}
#if JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION
} }
#endif
sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_padding_type"); sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_padding_type");
sei.m_paddingType = val; sei.m_paddingType = val;
......
...@@ -778,6 +778,10 @@ protected: ...@@ -778,6 +778,10 @@ protected:
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationRightOffset[MAX_NUM_NN_POST_FILTERS];
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[MAX_NUM_NN_POST_FILTERS];
int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[MAX_NUM_NN_POST_FILTERS]; int32_t m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[MAX_NUM_NN_POST_FILTERS];
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
bool m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[MAX_NUM_NN_POST_FILTERS];
std::string m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[MAX_NUM_NN_POST_FILTERS];
#endif
#endif #endif
std::vector<bool> m_nnPostFilterSEICharacteristicsInputPicOutputFlag[MAX_NUM_NN_POST_FILTERS]; std::vector<bool> m_nnPostFilterSEICharacteristicsInputPicOutputFlag[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[MAX_NUM_NN_POST_FILTERS]; bool m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[MAX_NUM_NN_POST_FILTERS];
...@@ -2184,6 +2188,12 @@ public: ...@@ -2184,6 +2188,12 @@ public:
int32_t getNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset(int filterIdx) { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[filterIdx]; } int32_t getNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset(int filterIdx) { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationTopOffset[filterIdx]; }
void setNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(int32_t value, int filterIdx) { m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[filterIdx] = value; } void setNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(int32_t value, int filterIdx) { m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[filterIdx] = value; }
int32_t getNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(int filterIdx) { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[filterIdx]; } int32_t getNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(int filterIdx) { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset[filterIdx]; }
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
void setNNPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag(bool promptPresentFlag, int filterIdx) { m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[filterIdx] = promptPresentFlag; }
bool getNNPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag(int filterIdx) const { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag[filterIdx]; }
void setNNPostFilterSEICharacteristicsSpatialExrapolationPrompt(std::string prompt, int filterIdx) { m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[filterIdx] = prompt; }
std::string getNNPostFilterSEICharacteristicsSpatialExrapolationPrompt(int filterIdx) const { return m_nnPostFilterSEICharacteristicsSpatialExtrapolationPrompt[filterIdx]; }
#endif
#endif #endif
void setNNPostFilterSEICharacteristicsInputPicOutputFlag(std::vector<bool> value, int filterIdx) { m_nnPostFilterSEICharacteristicsInputPicOutputFlag[filterIdx] = value; } void setNNPostFilterSEICharacteristicsInputPicOutputFlag(std::vector<bool> value, int filterIdx) { m_nnPostFilterSEICharacteristicsInputPicOutputFlag[filterIdx] = value; }
const std::vector<bool>& getNNPostFilterSEICharacteristicsInputPicOutputFlag(int filterIdx) { return m_nnPostFilterSEICharacteristicsInputPicOutputFlag[filterIdx]; } const std::vector<bool>& getNNPostFilterSEICharacteristicsInputPicOutputFlag(int filterIdx) { return m_nnPostFilterSEICharacteristicsInputPicOutputFlag[filterIdx]; }
......
...@@ -1662,6 +1662,13 @@ void SEIEncoder::initSEINeuralNetworkPostFilterCharacteristics(SEINeuralNetworkP ...@@ -1662,6 +1662,13 @@ void SEIEncoder::initSEINeuralNetworkPostFilterCharacteristics(SEINeuralNetworkP
sei->m_spatialExtrapolationRightOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationRightOffset(filterIdx); sei->m_spatialExtrapolationRightOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationRightOffset(filterIdx);
sei->m_spatialExtrapolationTopOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset(filterIdx); sei->m_spatialExtrapolationTopOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationTopOffset(filterIdx);
sei->m_spatialExtrapolationBottomOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(filterIdx); sei->m_spatialExtrapolationBottomOffset = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationBottomOffset(filterIdx);
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
sei->m_spatialExtrapolationPromptPresentFlag = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExtrapolationPromptPresentFlag(filterIdx);
if (sei->m_spatialExtrapolationPromptPresentFlag)
{
sei->m_prompt = m_pcCfg->getNNPostFilterSEICharacteristicsSpatialExrapolationPrompt(filterIdx);
}
#endif
} }
#endif #endif
......
...@@ -1933,6 +1933,17 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN ...@@ -1933,6 +1933,17 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN
xWriteSvlc(sei.m_spatialExtrapolationRightOffset, "nnpfc_spatial_extrapolation_right_offset"); xWriteSvlc(sei.m_spatialExtrapolationRightOffset, "nnpfc_spatial_extrapolation_right_offset");
xWriteSvlc(sei.m_spatialExtrapolationTopOffset, "nnpfc_spatial_extrapolation_top_offset"); xWriteSvlc(sei.m_spatialExtrapolationTopOffset, "nnpfc_spatial_extrapolation_top_offset");
xWriteSvlc(sei.m_spatialExtrapolationBottomOffset, "nnpfc_spatial_extrapolation_right_offset"); xWriteSvlc(sei.m_spatialExtrapolationBottomOffset, "nnpfc_spatial_extrapolation_right_offset");
#if JVET_AI0061_SPATIAL_EXTRAPOLATION_PROPOSAL1
xWriteFlag(sei.m_spatialExtrapolationPromptPresentFlag, "nnpfc_spatial_extrapolation_prompt_present_flag");
if (sei.m_spatialExtrapolationPromptPresentFlag)
{
while (!isByteAligned())
{
xWriteFlag(0, "nnpfc_alignment_zero_bit_c");
}
xWriteString(sei.m_prompt, "nnpfc_prompt");
}
#endif
} }
#endif #endif
...@@ -1993,18 +2004,25 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN ...@@ -1993,18 +2004,25 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN
xWriteUvlc(to_underlying(sei.m_chromaSampleLocTypeFrame), "nnpfc_chroma_sample_loc_type_frame"); xWriteUvlc(to_underlying(sei.m_chromaSampleLocTypeFrame), "nnpfc_chroma_sample_loc_type_frame");
} }
xWriteUvlc(sei.m_overlap, "nnpfc_overlap"); #if JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION
xWriteFlag(sei.m_constantPatchSizeFlag, "nnpfc_constant_patch_size_flag"); if((sei.m_purpose & NNPC_PurposeType::SPATIAL_EXTRAPOLATION) == 0)
if (sei.m_constantPatchSizeFlag)
{
xWriteUvlc(sei.m_patchWidthMinus1, "nnpfc_patch_width_minus1");
xWriteUvlc(sei.m_patchHeightMinus1, "nnpfc_patch_height_minus1");
}
else
{ {
xWriteUvlc(sei.m_extendedPatchWidthCdDeltaMinus1, "extended_nnpfc_patch_width_cd_delta_minus1"); #endif
xWriteUvlc(sei.m_extendedPatchHeightCdDeltaMinus1, "extended_nnpfc_patch_height_cd_delta_minus1"); xWriteUvlc(sei.m_overlap, "nnpfc_overlap");
xWriteFlag(sei.m_constantPatchSizeFlag, "nnpfc_constant_patch_size_flag");
if (sei.m_constantPatchSizeFlag)
{
xWriteUvlc(sei.m_patchWidthMinus1, "nnpfc_patch_width_minus1");
xWriteUvlc(sei.m_patchHeightMinus1, "nnpfc_patch_height_minus1");
}
else
{
xWriteUvlc(sei.m_extendedPatchWidthCdDeltaMinus1, "extended_nnpfc_patch_width_cd_delta_minus1");
xWriteUvlc(sei.m_extendedPatchHeightCdDeltaMinus1, "extended_nnpfc_patch_height_cd_delta_minus1");
}
#if JVET_AI0061_PROPOSAL2_SPATIAL_EXTRAPOLATION
} }
#endif
xWriteUvlc(sei.m_paddingType, "nnpfc_padding_type"); xWriteUvlc(sei.m_paddingType, "nnpfc_padding_type");
if (sei.m_paddingType == NNPC_PaddingType::FIXED_PADDING) if (sei.m_paddingType == NNPC_PaddingType::FIXED_PADDING)
{ {
......
...@@ -1478,8 +1478,10 @@ bool VideoIOYuv::writeUpscaledPicture(const SPS &sps, const PPS &pps, const CPel ...@@ -1478,8 +1478,10 @@ bool VideoIOYuv::writeUpscaledPicture(const SPS &sps, const PPS &pps, const CPel
else else
{ {
const Window &conf = pps.getConformanceWindow(); const Window &conf = pps.getConformanceWindow();
int curPicWidth = maxWidth - SPS::getWinUnitX( sps.getChromaFormatIdc() ) * ( afterScaleWindowFullResolution.getWindowLeftOffset() + afterScaleWindowFullResolution.getWindowRightOffset() );
int curPicHeight = maxHeight - SPS::getWinUnitY( sps.getChromaFormatIdc() ) * ( afterScaleWindowFullResolution.getWindowTopOffset() + afterScaleWindowFullResolution.getWindowBottomOffset() );
ret = write(maxWidth, maxHeight, pic, ipCSC, ret = write(curPicWidth, curPicHeight, pic, ipCSC,
packedYuvOutputMode, conf.getWindowLeftOffset() * SPS::getWinUnitX(chromaFormatIdc), packedYuvOutputMode, conf.getWindowLeftOffset() * SPS::getWinUnitX(chromaFormatIdc),
conf.getWindowRightOffset() * SPS::getWinUnitX(chromaFormatIdc), conf.getWindowRightOffset() * SPS::getWinUnitX(chromaFormatIdc),
conf.getWindowTopOffset() * SPS::getWinUnitY(chromaFormatIdc), conf.getWindowTopOffset() * SPS::getWinUnitY(chromaFormatIdc),
......