diff --git a/source/App/EncoderApp/EncApp.cpp b/source/App/EncoderApp/EncApp.cpp
index a178e0018e4993c9c2c83914a67542a6aa6cbb8e..f358bfad0ceaa23edc09e7261a036345a48c6c34 100644
--- a/source/App/EncoderApp/EncApp.cpp
+++ b/source/App/EncoderApp/EncApp.cpp
@@ -1188,7 +1188,7 @@ void EncApp::xInitLibCfg( int layerIdx )
     {
       m_cEncLib.setNNPostFilterSEICharacteristicsPurpose                 (m_nnPostFilterSEICharacteristicsPurpose[i], i);
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & 0x02) != 0)
+      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0)
 #else
       if (m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) == 2  || m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) == 4)
 #endif
@@ -1202,7 +1202,7 @@ void EncApp::xInitLibCfg( int layerIdx )
       }
 #endif
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & 0x04) != 0)
+      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & NNPC_PurposeType::RESOLUTION_UPSAMPLING) != 0)
 #else
       if (m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) == 3  || m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) == 4)
 #endif
@@ -1211,7 +1211,7 @@ void EncApp::xInitLibCfg( int layerIdx )
         m_cEncLib.setNNPostFilterSEICharacteristicsPicHeightInLumaSamples  (m_nnPostFilterSEICharacteristicsPicHeightInLumaSamples[i], i);
       }
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & 0x08) != 0)
+      if ((m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) & NNPC_PurposeType::FRAME_RATE_UPSAMPLING) != 0)
 #else
       if (m_cEncLib.getNNPostFilterSEICharacteristicsPurpose(i) == 5)
 #endif
diff --git a/source/Lib/DecoderLib/SEIread.cpp b/source/Lib/DecoderLib/SEIread.cpp
index 96aa56a9fc4d256bb8003cd39f912ebac4a5a531..a14da8ab2c3083a92d7822f6e8c51ec6509ebb2d 100644
--- a/source/Lib/DecoderLib/SEIread.cpp
+++ b/source/Lib/DecoderLib/SEIread.cpp
@@ -2715,7 +2715,7 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
 #endif
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x02) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0)
 #else
     if(sei.m_purpose == 2 || sei.m_purpose == 4)
 #endif
@@ -2746,7 +2746,7 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
 #endif
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    CHECK(((subWidthC == 1) && (subHeightC == 1)) && ((sei.m_purpose & 0x02) != 0),
+    CHECK(((subWidthC == 1) && (subHeightC == 1)) && ((sei.m_purpose & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0),
           "If SubWidthC is equal to 1 and SubHeightC is equal to 1, nnpfc_purpose & 0x02 shall be equal to 0");
 #else
     CHECK(((subWidthC == 1) && (subHeightC == 1)) && ((sei.m_purpose == 2) || (sei.m_purpose == 4)),
@@ -2775,7 +2775,7 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
 #endif
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x04) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::RESOLUTION_UPSAMPLING) != 0)
 #else
     if(sei.m_purpose == 3 || sei.m_purpose == 4)
 #endif
@@ -2787,7 +2787,7 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
     }
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x08) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::FRAME_RATE_UPSAMPLING) != 0)
 #else
     if(sei.m_purpose == NNPC_PurposeType::FRAME_RATE_UPSAMPLING)
 #endif
@@ -2869,7 +2869,7 @@ void SEIReader::xParseSEINNPostFilterCharacteristics(SEINeuralNetworkPostFilterC
     sei_read_uvlc(pDecodedMessageOutputStream, val, "nnpfc_out_order_idc");
     sei.m_outOrderIdc = val;
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    CHECK(((sei.m_purpose & 0x02) != 0)  && (sei.m_outOrderIdc == 3), "When nnpfc_purpose & 0x02 is not equal to 0, nnpfc_out_order_idc shall not be equal to 3.")
+    CHECK(((sei.m_purpose & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0)  && (sei.m_outOrderIdc == 3), "When nnpfc_purpose & 0x02 is not equal to 0, nnpfc_out_order_idc shall not be equal to 3.")
 #endif
 
     sei_read_flag(pDecodedMessageOutputStream, val, "nnpfc_constant_patch_size_flag");
diff --git a/source/Lib/EncoderLib/SEIEncoder.cpp b/source/Lib/EncoderLib/SEIEncoder.cpp
index e2dac34ce48fb316c4cee6c490a1b84fdd76a6d3..156150e2bb620ba939215d40cc0f09295607fd77 100644
--- a/source/Lib/EncoderLib/SEIEncoder.cpp
+++ b/source/Lib/EncoderLib/SEIEncoder.cpp
@@ -1319,7 +1319,7 @@ void SEIEncoder::initSEINeuralNetworkPostFilterCharacteristics(SEINeuralNetworkP
 #endif
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei->m_purpose & 0x02) != 0)
+    if((sei->m_purpose & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0)
 #else
     if(sei->m_purpose == 2 || sei->m_purpose == 4)
 #endif
@@ -1333,7 +1333,7 @@ void SEIEncoder::initSEINeuralNetworkPostFilterCharacteristics(SEINeuralNetworkP
     }
 #endif
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei->m_purpose & 0x04) != 0)
+    if((sei->m_purpose & NNPC_PurposeType::RESOLUTION_UPSAMPLING) != 0)
 #else
     if(sei->m_purpose == 3 || sei->m_purpose == 4)
 #endif
@@ -1371,7 +1371,7 @@ void SEIEncoder::initSEINeuralNetworkPostFilterCharacteristics(SEINeuralNetworkP
       CHECK(!(sei->m_picHeightInLumaSamples >= croppedHeight && sei->m_picHeightInLumaSamples <= croppedHeight * 16 - 1), "m_picHeightInLumaSamples shall be in the range of croppedHeight to croppedHeight * 16 - 1");
     }
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei->m_purpose & 0x08) != 0)
+    if((sei->m_purpose & NNPC_PurposeType::FRAME_RATE_UPSAMPLING) != 0)
 #else
     if (sei->m_purpose == NNPC_PurposeType::FRAME_RATE_UPSAMPLING)
 #endif
diff --git a/source/Lib/EncoderLib/SEIwrite.cpp b/source/Lib/EncoderLib/SEIwrite.cpp
index 092b8ef02e1dbd97165f7c932d12c9ee609b5142..f97dbff283f00ce73b254fd416bce5a32c82bc54 100644
--- a/source/Lib/EncoderLib/SEIwrite.cpp
+++ b/source/Lib/EncoderLib/SEIwrite.cpp
@@ -1705,7 +1705,7 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN
 #endif
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x02) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::CHROMA_UPSAMPLING) != 0)
 #else
     if(sei.m_purpose == 2 || sei.m_purpose == 4)
 #endif
@@ -1719,7 +1719,7 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN
     }
 #endif
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x04) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::RESOLUTION_UPSAMPLING) != 0)
 #else
     if(sei.m_purpose == 3 || sei.m_purpose == 4)
 #endif
@@ -1729,7 +1729,7 @@ void SEIWriter::xWriteSEINeuralNetworkPostFilterCharacteristics(const SEINeuralN
     }
 
 #if JVET_AC0127_BIT_MASKING_NNPFC_PURPOSE
-    if((sei.m_purpose & 0x08) != 0)
+    if((sei.m_purpose & NNPC_PurposeType::FRAME_RATE_UPSAMPLING) != 0)
 #else
     if (sei.m_purpose == NNPC_PurposeType::FRAME_RATE_UPSAMPLING) 
 #endif