From 747ce1cdc3c1071eea48e319dff20d03a763797f Mon Sep 17 00:00:00 2001
From: Karsten Suehring <karsten.suehring@hhi.fraunhofer.de>
Date: Sun, 19 Apr 2020 10:36:25 +0200
Subject: [PATCH] Cleanup: restructure picture partitioning config files

- remove picture partitioning section from CTC file (so that they can be combined wit partitioning in any order)
- remove random access parameters from partitioning examples (combines well with AI or LD too)
- add examples for three slices with slice layout inference from subpictures and without
- try to make naming somewhat consistent
---
 cfg/encoder_intra_vtm.cfg                     |   3 -
 cfg/encoder_lowdelay_P_vtm.cfg                |   3 -
 cfg/encoder_lowdelay_vtm.cfg                  |   3 -
 cfg/encoder_randomaccess_vtm.cfg              |   3 -
 .../two_layers.cfg}                           |   0
 ...coder_randomaccess_vtm_RasterScanSlice.cfg | 161 -----------------
 ...omaccess_vtm_RectangularSliceFixedSize.cfg | 163 ------------------
 ...er_randomaccess_vtm_SingleTilePerSlice.cfg | 160 -----------------
 cfg/partitioning/raster_slice.cfg             |  13 ++
 .../raster_slice_1_slice_per_tile.cfg         |  11 ++
 .../rect_slice_classB.cfg}                    |  11 +-
 cfg/partitioning/rect_slice_fixed_size.cfg    |  14 ++
 .../subpicture_3_slice_2_tile.cfg             |  38 ++++
 ...ture_3_slice_2_tile_1_slice_per_subpic.cfg |  39 +++++
 .../subpicture_4_slice_2_hor_subpic.cfg}      |   0
 .../subpicture_4_slice_2_ver_subpic.cfg}      |   0
 .../subpicture_8_slice_12_tile_2_subpic.cfg}  |   3 -
 17 files changed, 119 insertions(+), 506 deletions(-)
 rename cfg/{layers.cfg => multi-layer/two_layers.cfg} (100%)
 delete mode 100644 cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RasterScanSlice.cfg
 delete mode 100644 cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RectangularSliceFixedSize.cfg
 delete mode 100644 cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_SingleTilePerSlice.cfg
 create mode 100644 cfg/partitioning/raster_slice.cfg
 create mode 100644 cfg/partitioning/raster_slice_1_slice_per_tile.cfg
 rename cfg/{nonCTC-SliceConfigExamples/encoder_rectangular_slice_classB.cfg => partitioning/rect_slice_classB.cfg} (88%)
 create mode 100644 cfg/partitioning/rect_slice_fixed_size.cfg
 create mode 100644 cfg/partitioning/subpicture_3_slice_2_tile.cfg
 create mode 100644 cfg/partitioning/subpicture_3_slice_2_tile_1_slice_per_subpic.cfg
 rename cfg/{nonCTC-SliceConfigExamples/subpicture_4Slice2HorSubPic.cfg => partitioning/subpicture_4_slice_2_hor_subpic.cfg} (100%)
 rename cfg/{nonCTC-SliceConfigExamples/subpicture_4Slice2VerSubPic.cfg => partitioning/subpicture_4_slice_2_ver_subpic.cfg} (100%)
 rename cfg/{nonCTC-SliceConfigExamples/TwoSubpictures_with_EightSlices.cfg => partitioning/subpicture_8_slice_12_tile_2_subpic.cfg} (97%)

diff --git a/cfg/encoder_intra_vtm.cfg b/cfg/encoder_intra_vtm.cfg
index 87c05f8fb..64a3c797b 100644
--- a/cfg/encoder_intra_vtm.cfg
+++ b/cfg/encoder_intra_vtm.cfg
@@ -51,9 +51,6 @@ TransformSkipFast             : 1           # Fast Transform skipping (0: OFF, 1
 TransformSkipLog2MaxSize      : 5
 SAOLcuBoundary                : 0           # SAOLcuBoundary using non-deblocked pixels (0: OFF, 1: ON)
 
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 0           # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
 #============ VTM settings ======================
 SEIDecodedPictureHash               : 0
 CbQpOffset                          : 0
diff --git a/cfg/encoder_lowdelay_P_vtm.cfg b/cfg/encoder_lowdelay_P_vtm.cfg
index c367d4f39..36f3b89d6 100644
--- a/cfg/encoder_lowdelay_P_vtm.cfg
+++ b/cfg/encoder_lowdelay_P_vtm.cfg
@@ -68,9 +68,6 @@ TemporalFilter                : 0           # Enable/disable GOP Based Temporal
 TemporalFilterFutureReference : 0           # Enable/disable reading future frames
 TemporalFilterStrengthFrame4  : 0.4         # Enable filter at every 4th frame with strength
 
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 0           # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
 #============ Rate Control ======================
 RateControl                         : 0                # Rate control: enable rate control
 TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
diff --git a/cfg/encoder_lowdelay_vtm.cfg b/cfg/encoder_lowdelay_vtm.cfg
index 251213b76..228ecb5ee 100644
--- a/cfg/encoder_lowdelay_vtm.cfg
+++ b/cfg/encoder_lowdelay_vtm.cfg
@@ -68,9 +68,6 @@ TemporalFilter                : 0           # Enable/disable GOP Based Temporal
 TemporalFilterFutureReference : 0           # Enable/disable reading future frames
 TemporalFilterStrengthFrame4  : 0.4         # Enable filter at every 4th frame with strength
 
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 0           # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
 #============ Rate Control ======================
 RateControl                         : 0                # Rate control: enable rate control
 TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
diff --git a/cfg/encoder_randomaccess_vtm.cfg b/cfg/encoder_randomaccess_vtm.cfg
index 82b1bc4b8..b50b5fd16 100644
--- a/cfg/encoder_randomaccess_vtm.cfg
+++ b/cfg/encoder_randomaccess_vtm.cfg
@@ -79,9 +79,6 @@ TemporalFilterFutureReference : 1           # Enable/disable reading future fram
 TemporalFilterStrengthFrame8  : 0.95        # Enable filter at every 8th frame with given strength
 TemporalFilterStrengthFrame16 : 1.5         # Enable filter at every 16th frame with given strength, longer intervals has higher priority
 
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 0           # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
 #============ Rate Control ======================
 RateControl                         : 0                # Rate control: enable rate control
 TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
diff --git a/cfg/layers.cfg b/cfg/multi-layer/two_layers.cfg
similarity index 100%
rename from cfg/layers.cfg
rename to cfg/multi-layer/two_layers.cfg
diff --git a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RasterScanSlice.cfg b/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RasterScanSlice.cfg
deleted file mode 100644
index b1fbeb3ed..000000000
--- a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RasterScanSlice.cfg
+++ /dev/null
@@ -1,161 +0,0 @@
-#======== File I/O =====================
-BitstreamFile                 : str.bin
-ReconFile                     : rec.yuv
-
-#======== Profile ================
-Profile                       : auto
-
-#======== Unit definition ================
-MaxCUWidth                    : 64          # Maximum coding unit width in pixel
-MaxCUHeight                   : 64          # Maximum coding unit height in pixel
-
-#======== Coding Structure =============
-IntraPeriod                   : 32          # Period of I-Frame ( -1 = only first)
-DecodingRefreshType           : 1           # Random Accesss 0:none, 1:CRA, 2:IDR, 3:Recovery Point SEI
-GOPSize                       : 16          # GOP Size (number of B slice = GOPSize-1)
-
-IntraQPOffset                 : -3
-LambdaFromQpEnable            : 1           # see JCTVC-X0038 for suitable parameters for IntraQPOffset, QPoffset, QPOffsetModelOff, QPOffsetModelScale when enabled
-#        Type POC QPoffset QPOffsetModelOff QPOffsetModelScale CbQPoffset CrQPoffset QPfactor tcOffsetDiv2 betaOffsetDiv2 CbTcOffsetDiv2 CbBetaOffsetDiv2 CrTcOffsetDiv2 CrBetaOffsetDiv2 temporal_id #ref_pics_active_L0 #ref_pics_L0   reference_pictures_L0 #ref_pics_active_L1 #ref_pics_L1   reference_pictures_L1
-Frame1:   B   16   1        0.0                      0.0            0          0          1.0      0            0              0               0                0               0              0             2                3          16 32 24                    2                2           16 32
-Frame2:   B    8   1       -4.8848                   0.2061         0          0          1.0      0            0              0               0                0               0              1             2                2          8 16                        2                2           -8 8
-Frame3:   B    4   4       -5.7476                   0.2286         0          0          1.0      0            0              0               0                0               0              2             2                2          4 12                        2                2           -4 -12
-Frame4:   B    2   5       -5.90                     0.2333         0          0          1.0      0            0              0               0                0               0              3             2                2          2 10                        2                3           -2 -6 -14
-Frame5:   B    1   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                2          1 -1                        2                4           -1 -3 -7 -15
-Frame6:   B    3   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                2          1 3                         2                3           -1 -5 -13
-Frame7:   B    6   5       -5.90                     0.2333         0          0          1.0      0            0              0               0                0               0              3             2                2          2 6                         2                2           -2 -10
-Frame8:   B    5   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                2          1 5                         2                3           -1 -3 -11
-Frame9:   B    7   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                3          1 3 7                       2                2           -1 -9
-Frame10:  B   12   4       -5.7476                   0.2286         0          0          1.0      0            0              0               0                0               0              2             2                2          4 12                        2                2           -4 4
-Frame11:  B   10   5       -5.90                     0.2333         0          0          1.0      0            0              0               0                0               0              3             2                2          2 10                        2                2           -2 -6
-Frame12:  B    9   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                2          1 9                         2                3           -1 -3 -7
-Frame13:  B   11   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                3          1 3 11                      2                2           -1 -5
-Frame14:  B   14   5       -5.90                     0.2333         0          0          1.0      0            0              0               0                0               0              3             2                3          2 6 14                      2                2           -2 2
-Frame15:  B   13   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                3          1 5 13                      2                2           -1 -3
-Frame16:  B   15   6       -7.1444                   0.3            0          0          1.0      0            0              0               0                0               0              4             2                4          1 3 7 15                    2                2           -1 1
-
-#=========== Motion Search =============
-FastSearch                    : 1           # 0:Full search  1:TZ search
-SearchRange                   : 384         # (0: Search range is a Full frame)
-ASR                           : 1           # Adaptive motion search range
-MinSearchWindow               : 96          # Minimum motion search window size for the adaptive window ME
-BipredSearchRange             : 4           # Search range for bi-prediction refinement
-HadamardME                    : 1           # Use of hadamard measure for fractional ME
-FEN                           : 1           # Fast encoder decision
-FDM                           : 1           # Fast Decision for Merge RD cost
-
-#======== Quantization =============
-QP                            : 32          # Quantization parameter(0-51)
-MaxDeltaQP                    : 0           # CU-based multi-QP optimization
-MaxCuDQPSubdiv                : 0           # Maximum subdiv for CU luma Qp adjustment
-DeltaQpRD                     : 0           # Slice-based multi-QP optimization
-RDOQ                          : 1           # RDOQ
-RDOQTS                        : 1           # RDOQ for transform skip
-
-#=========== Deblock Filter ============
-LoopFilterOffsetInPPS         : 1           # Dbl params: 0=varying params in SliceHeader, param = base_param + GOP_offset_param; 1 (default) =constant params in PPS, param = base_param)
-LoopFilterDisable             : 0           # Disable deblocking filter (0=Filter, 1=No Filter)
-LoopFilterBetaOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterTcOffset_div2       : 0           # base_param: -12 ~ 12
-LoopFilterCbBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCbTcOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterCrBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCrTcOffset_div2     : 0           # base_param: -12 ~ 12
-DeblockingFilterMetric        : 0           # blockiness metric (automatically configures deblocking parameters in bitstream). Applies slice-level loop filter offsets (LoopFilterOffsetInPPS and LoopFilterDisable must be 0)
-
-#=========== Misc. ============
-InternalBitDepth              : 10          # codec operating bit-depth
-
-#=========== Coding Tools =================
-SAO                           : 1           # Sample adaptive offset  (0: OFF, 1: ON)
-TransformSkip                 : 1           # Transform skipping (0: OFF, 1: ON)
-TransformSkipFast             : 1           # Fast Transform skipping (0: OFF, 1: ON)
-TransformSkipLog2MaxSize      : 5
-SAOLcuBoundary                : 0           # SAOLcuBoundary using non-deblocked pixels (0: OFF, 1: ON)
-
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 1                      # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
-# Figure 4 - Section 6.3.1 - 12 tiles and 3 raster-scan slices
-TileColumnWidthArray          : 6 6 6                  # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
-TileRowHeightArray            : 3 3 3 3                # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
-RasterScanSlices              : 1                      # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
-RasterSliceSizes              : 2 5 5                  # Raster-scan slice sizes in units of tiles. Last slice size will be repeated uniformly to cover any remaining tiles in the picture
-DisableLoopFilterAcrossTiles  : 0                      # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
-DisableLoopFilterAcrossSlices : 0                      # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
-
-#============ Rate Control ======================
-RateControl                         : 0                # Rate control: enable rate control
-TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
-KeepHierarchicalBit                 : 2                # Rate control: 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation
-LCULevelRateControl                 : 1                # Rate control: 1: LCU level RC; 0: picture level RC
-RCLCUSeparateModel                  : 1                # Rate control: use LCU level separate R-lambda model
-InitialQP                           : 0                # Rate control: initial QP
-RCForceIntraQP                      : 0                # Rate control: force intra QP to be equal to initial QP
-
-#============ VTM settings ======================
-LoopFilterTcOffset_div2             : 0
-SEIDecodedPictureHash               : 0
-CbQpOffset                          : 1
-CrQpOffset                          : 1
-
-ReWriteParamSets                    : 1
-#============ NEXT ====================
-
-# General
-CTUSize                      : 128
-LCTUFast                     : 1
-
-DualITree                    : 1      # separate partitioning of luma and chroma channels for I-slices
-MinQTLumaISlice              : 8
-MinQTChromaISliceInChromaSamples: 4      # minimum QT size in chroma samples for chroma separate tree
-MinQTNonISlice               : 8
-MaxMTTHierarchyDepth         : 3
-MaxMTTHierarchyDepthISliceL  : 3
-MaxMTTHierarchyDepthISliceC  : 3
-
-MTS                          : 1
-MTSIntraMaxCand              : 3
-MTSInterMaxCand              : 4
-SBT                          : 1
-LFNST			     : 1
-ISP                          : 1
-MMVD                         : 1
-Affine                       : 1
-SubPuMvp                     : 1
-MaxNumMergeCand              : 6
-LMChroma                     : 1      # use CCLM only
-DepQuant                     : 1
-IMV                          : 1
-ALF                          : 1
-BCW                          : 1 
-BcwFast                      : 1
-BIO                          : 1 
-CIIP                         : 1
-IBC                          : 0      # turned off in CTC
-AllowDisFracMMVD             : 1
-AffineAmvr                   : 1
-LMCSEnable                   : 1      # LMCS: 0: disable, 1:enable
-LMCSSignalType               : 0      # Input signal type: 0:SDR, 1:HDR-PQ, 2:HDR-HLG
-LMCSUpdateCtrl               : 0      # LMCS model update control: 0:RA, 1:AI, 2:LDB/LDP
-MRL                          : 1
-MIP                          : 1
-DMVR                         : 1
-SMVD                         : 1
-
-# Fast tools
-PBIntraFast                  : 1
-ISPFast                      : 1
-FastMrg                      : 1
-AMaxBT                       : 1
-FastMIP                      : 0
-FastLFNST		     : 0
-
-# Encoder optimization tools
-AffineAmvrEncOpt             : 1
-MmvdDisNum		     : 6
-### DO NOT ADD ANYTHING BELOW THIS LINE ###
-### DO NOT DELETE THE EMPTY LINE BELOW ###
-
-
-
diff --git a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RectangularSliceFixedSize.cfg b/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RectangularSliceFixedSize.cfg
deleted file mode 100644
index 7182428dc..000000000
--- a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_RectangularSliceFixedSize.cfg
+++ /dev/null
@@ -1,163 +0,0 @@
-#======== File I/O =====================
-BitstreamFile                 : str.bin
-ReconFile                     : rec.yuv
-
-#======== Profile ================
-Profile                       : auto
-
-#======== Unit definition ================
-MaxCUWidth                    : 64          # Maximum coding unit width in pixel
-MaxCUHeight                   : 64          # Maximum coding unit height in pixel
-
-#======== Coding Structure =============
-IntraPeriod                   : 32          # Period of I-Frame ( -1 = only first)
-DecodingRefreshType           : 1           # Random Accesss 0:none, 1:CRA, 2:IDR, 3:Recovery Point SEI
-GOPSize                       : 16          # GOP Size (number of B slice = GOPSize-1)
-
-IntraQPOffset                 : -3
-LambdaFromQpEnable            : 1           # see JCTVC-X0038 for suitable parameters for IntraQPOffset, QPoffset, QPOffsetModelOff, QPOffsetModelScale when enabled
-#        Type POC QPoffset QPOffsetModelOff QPOffsetModelScale CbQPoffset CrQPoffset QPfactor tcOffsetDiv2 betaOffsetDiv2 CbTcOffsetDiv2 CbBetaOffsetDiv2 CrTcOffsetDiv2 CrBetaOffsetDiv2 temporal_id #ref_pics_active_L0 #ref_pics_L0   reference_pictures_L0 #ref_pics_active_L1 #ref_pics_L1   reference_pictures_L1
-Frame1:   B   16   1        0.0                      0.0            0          0          1.0      0            0              0                0              0                0              0             2                3          16 32 24                    2                2           16 32
-Frame2:   B    8   1       -4.8848                   0.2061         0          0          1.0      0            0              0                0              0                0              1             2                2          8 16                        2                2           -8 8
-Frame3:   B    4   4       -5.7476                   0.2286         0          0          1.0      0            0              0                0              0                0              2             2                2          4 12                        2                2           -4 -12
-Frame4:   B    2   5       -5.90                     0.2333         0          0          1.0      0            0              0                0              0                0              3             2                2          2 10                        2                3           -2 -6 -14
-Frame5:   B    1   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                2          1 -1                        2                4           -1 -3 -7 -15
-Frame6:   B    3   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                2          1 3                         2                3           -1 -5 -13
-Frame7:   B    6   5       -5.90                     0.2333         0          0          1.0      0            0              0                0              0                0              3             2                2          2 6                         2                2           -2 -10
-Frame8:   B    5   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                2          1 5                         2                3           -1 -3 -11
-Frame9:   B    7   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                3          1 3 7                       2                2           -1 -9
-Frame10:  B   12   4       -5.7476                   0.2286         0          0          1.0      0            0              0                0              0                0              2             2                2          4 12                        2                2           -4 4
-Frame11:  B   10   5       -5.90                     0.2333         0          0          1.0      0            0              0                0              0                0              3             2                2          2 10                        2                2           -2 -6
-Frame12:  B    9   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                2          1 9                         2                3           -1 -3 -7
-Frame13:  B   11   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                3          1 3 11                      2                2           -1 -5
-Frame14:  B   14   5       -5.90                     0.2333         0          0          1.0      0            0              0                0              0                0              3             2                3          2 6 14                      2                2           -2 2
-Frame15:  B   13   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                3          1 5 13                      2                2           -1 -3
-Frame16:  B   15   6       -7.1444                   0.3            0          0          1.0      0            0              0                0              0                0              4             2                4          1 3 7 15                    2                2           -1 1
-
-#=========== Motion Search =============
-FastSearch                    : 1           # 0:Full search  1:TZ search
-SearchRange                   : 384         # (0: Search range is a Full frame)
-ASR                           : 1           # Adaptive motion search range
-MinSearchWindow               : 96          # Minimum motion search window size for the adaptive window ME
-BipredSearchRange             : 4           # Search range for bi-prediction refinement
-HadamardME                    : 1           # Use of hadamard measure for fractional ME
-FEN                           : 1           # Fast encoder decision
-FDM                           : 1           # Fast Decision for Merge RD cost
-
-#======== Quantization =============
-QP                            : 32          # Quantization parameter(0-51)
-MaxDeltaQP                    : 0           # CU-based multi-QP optimization
-MaxCuDQPSubdiv                : 0           # Maximum subdiv for CU luma Qp adjustment
-DeltaQpRD                     : 0           # Slice-based multi-QP optimization
-RDOQ                          : 1           # RDOQ
-RDOQTS                        : 1           # RDOQ for transform skip
-
-#=========== Deblock Filter ============
-LoopFilterOffsetInPPS         : 1           # Dbl params: 0=varying params in SliceHeader, param = base_param + GOP_offset_param; 1 (default) =constant params in PPS, param = base_param)
-LoopFilterDisable             : 0           # Disable deblocking filter (0=Filter, 1=No Filter)
-LoopFilterBetaOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterTcOffset_div2       : 0           # base_param: -12 ~ 12
-LoopFilterCbBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCbTcOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterCrBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCrTcOffset_div2     : 0           # base_param: -12 ~ 12
-DeblockingFilterMetric        : 0           # blockiness metric (automatically configures deblocking parameters in bitstream). Applies slice-level loop filter offsets (LoopFilterOffsetInPPS and LoopFilterDisable must be 0)
-
-#=========== Misc. ============
-InternalBitDepth              : 10          # codec operating bit-depth
-
-#=========== Coding Tools =================
-SAO                           : 1           # Sample adaptive offset  (0: OFF, 1: ON)
-TransformSkip                 : 1           # Transform skipping (0: OFF, 1: ON)
-TransformSkipFast             : 1           # Fast Transform skipping (0: OFF, 1: ON)
-TransformSkipLog2MaxSize      : 5
-SAOLcuBoundary                : 0           # SAOLcuBoundary using non-deblocked pixels (0: OFF, 1: ON)
-
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 1                         # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-
-# 24 tiles and 6 rectangular slices
-TileColumnWidthArray          : 3 3 3 3 3 3               # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
-TileRowHeightArray            : 3 3 3 3                   # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
-RasterScanSlices              : 0                         # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
-RectSliceFixedWidth           : 2                         # Fixed rectangular slice width in units of tiles (0: disable this feature and use RectSlicePositions instead)
-RectSliceFixedHeight          : 2                         # Fixed rectangular slice height in units of tiles (0: disable this feature and use RectSlicePositions instead)
-DisableLoopFilterAcrossTiles  : 0                         # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
-DisableLoopFilterAcrossSlices : 0                         # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
-
-#============ Rate Control ======================
-RateControl                         : 0                # Rate control: enable rate control
-TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
-KeepHierarchicalBit                 : 2                # Rate control: 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation
-LCULevelRateControl                 : 1                # Rate control: 1: LCU level RC; 0: picture level RC
-RCLCUSeparateModel                  : 1                # Rate control: use LCU level separate R-lambda model
-InitialQP                           : 0                # Rate control: initial QP
-RCForceIntraQP                      : 0                # Rate control: force intra QP to be equal to initial QP
-
-#============ VTM settings ======================
-LoopFilterTcOffset_div2             : 0
-SEIDecodedPictureHash               : 0
-CbQpOffset                          : 1
-CrQpOffset                          : 1
-
-ReWriteParamSets                    : 1
-#============ NEXT ====================
-
-# General
-CTUSize                      : 128
-LCTUFast                     : 1
-
-DualITree                    : 1      # separate partitioning of luma and chroma channels for I-slices
-MinQTLumaISlice              : 8
-MinQTChromaISliceInChromaSamples: 4      # minimum QT size in chroma samples for chroma separate tree
-MinQTNonISlice               : 8
-MaxMTTHierarchyDepth         : 3
-MaxMTTHierarchyDepthISliceL  : 3
-MaxMTTHierarchyDepthISliceC  : 3
-
-MTS                          : 1
-MTSIntraMaxCand              : 3
-MTSInterMaxCand              : 4
-SBT                          : 1
-LFNST			     : 1
-ISP                          : 1
-MMVD                         : 1
-Affine                       : 1
-SubPuMvp                     : 1
-MaxNumMergeCand              : 6
-LMChroma                     : 1      # use CCLM only
-DepQuant                     : 1
-IMV                          : 1
-ALF                          : 1
-BCW                          : 1 
-BcwFast                      : 1
-BIO                          : 1 
-CIIP                         : 1
-Triangle                     : 1
-IBC                          : 0      # turned off in CTC
-AllowDisFracMMVD             : 1
-AffineAmvr                   : 1
-LMCSEnable                   : 1      # LMCS: 0: disable, 1:enable
-LMCSSignalType               : 0      # Input signal type: 0:SDR, 1:HDR-PQ, 2:HDR-HLG
-LMCSUpdateCtrl               : 0      # LMCS model update control: 0:RA, 1:AI, 2:LDB/LDP
-MRL                          : 1
-MIP                          : 1
-DMVR                         : 1
-SMVD                         : 1
-
-# Fast tools
-PBIntraFast                  : 1
-ISPFast                      : 1
-FastMrg                      : 1
-AMaxBT                       : 1
-FastMIP                      : 0
-FastLFNST		     : 0
-
-# Encoder optimization tools
-AffineAmvrEncOpt             : 1
-MmvdDisNum		     : 6
-### DO NOT ADD ANYTHING BELOW THIS LINE ###
-### DO NOT DELETE THE EMPTY LINE BELOW ###
-
-
-
diff --git a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_SingleTilePerSlice.cfg b/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_SingleTilePerSlice.cfg
deleted file mode 100644
index c3a6a7e8f..000000000
--- a/cfg/nonCTC-SliceConfigExamples/encoder_randomaccess_vtm_SingleTilePerSlice.cfg
+++ /dev/null
@@ -1,160 +0,0 @@
-#======== File I/O =====================
-BitstreamFile                 : str.bin
-ReconFile                     : rec.yuv
-
-#======== Profile ================
-Profile                       : auto
-
-#======== Unit definition ================
-MaxCUWidth                    : 64          # Maximum coding unit width in pixel
-MaxCUHeight                   : 64          # Maximum coding unit height in pixel
-
-#======== Coding Structure =============
-IntraPeriod                   : 32          # Period of I-Frame ( -1 = only first)
-DecodingRefreshType           : 1           # Random Accesss 0:none, 1:CRA, 2:IDR, 3:Recovery Point SEI
-GOPSize                       : 16          # GOP Size (number of B slice = GOPSize-1)
-
-IntraQPOffset                 : -3
-LambdaFromQpEnable            : 1           # see JCTVC-X0038 for suitable parameters for IntraQPOffset, QPoffset, QPOffsetModelOff, QPOffsetModelScale when enabled
-#        Type POC QPoffset QPOffsetModelOff QPOffsetModelScale CbQPoffset CrQPoffset QPfactor tcOffsetDiv2 betaOffsetDiv2 CbTcOffsetDiv2 CbBetaOffsetDiv2 CrTcOffsetDiv2 CrBetaOffsetDiv2 temporal_id #ref_pics_active_L0 #ref_pics_L0   reference_pictures_L0 #ref_pics_active_L1 #ref_pics_L1   reference_pictures_L1
-Frame1:   B   16   1        0.0                      0.0            0          0          1.0      0            0              0                0               0               0              0             2                3          16 32 24                    2                2           16 32
-Frame2:   B    8   1       -4.8848                   0.2061         0          0          1.0      0            0              0                0               0               0              1             2                2          8 16                        2                2           -8 8
-Frame3:   B    4   4       -5.7476                   0.2286         0          0          1.0      0            0              0                0               0               0              2             2                2          4 12                        2                2           -4 -12
-Frame4:   B    2   5       -5.90                     0.2333         0          0          1.0      0            0              0                0               0               0              3             2                2          2 10                        2                3           -2 -6 -14
-Frame5:   B    1   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                2          1 -1                        2                4           -1 -3 -7 -15
-Frame6:   B    3   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                2          1 3                         2                3           -1 -5 -13
-Frame7:   B    6   5       -5.90                     0.2333         0          0          1.0      0            0              0                0               0               0              3             2                2          2 6                         2                2           -2 -10
-Frame8:   B    5   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                2          1 5                         2                3           -1 -3 -11
-Frame9:   B    7   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                3          1 3 7                       2                2           -1 -9
-Frame10:  B   12   4       -5.7476                   0.2286         0          0          1.0      0            0              0                0               0               0              2             2                2          4 12                        2                2           -4 4
-Frame11:  B   10   5       -5.90                     0.2333         0          0          1.0      0            0              0                0               0               0              3             2                2          2 10                        2                2           -2 -6
-Frame12:  B    9   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                2          1 9                         2                3           -1 -3 -7
-Frame13:  B   11   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                3          1 3 11                      2                2           -1 -5
-Frame14:  B   14   5       -5.90                     0.2333         0          0          1.0      0            0              0                0               0               0              3             2                3          2 6 14                      2                2           -2 2
-Frame15:  B   13   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                3          1 5 13                      2                2           -1 -3
-Frame16:  B   15   6       -7.1444                   0.3            0          0          1.0      0            0              0                0               0               0              4             2                4          1 3 7 15                    2                2           -1 1
-
-#=========== Motion Search =============
-FastSearch                    : 1           # 0:Full search  1:TZ search
-SearchRange                   : 384         # (0: Search range is a Full frame)
-ASR                           : 1           # Adaptive motion search range
-MinSearchWindow               : 96          # Minimum motion search window size for the adaptive window ME
-BipredSearchRange             : 4           # Search range for bi-prediction refinement
-HadamardME                    : 1           # Use of hadamard measure for fractional ME
-FEN                           : 1           # Fast encoder decision
-FDM                           : 1           # Fast Decision for Merge RD cost
-
-#======== Quantization =============
-QP                            : 32          # Quantization parameter(0-51)
-MaxDeltaQP                    : 0           # CU-based multi-QP optimization
-MaxCuDQPSubdiv                : 0           # Maximum subdiv for CU luma Qp adjustment
-DeltaQpRD                     : 0           # Slice-based multi-QP optimization
-RDOQ                          : 1           # RDOQ
-RDOQTS                        : 1           # RDOQ for transform skip
-
-#=========== Deblock Filter ============
-LoopFilterOffsetInPPS         : 1           # Dbl params: 0=varying params in SliceHeader, param = base_param + GOP_offset_param; 1 (default) =constant params in PPS, param = base_param)
-LoopFilterDisable             : 0           # Disable deblocking filter (0=Filter, 1=No Filter)
-LoopFilterBetaOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterTcOffset_div2       : 0           # base_param: -12 ~ 12
-LoopFilterCbBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCbTcOffset_div2     : 0           # base_param: -12 ~ 12
-LoopFilterCrBetaOffset_div2   : 0           # base_param: -12 ~ 12
-LoopFilterCrTcOffset_div2     : 0           # base_param: -12 ~ 12
-DeblockingFilterMetric        : 0           # blockiness metric (automatically configures deblocking parameters in bitstream). Applies slice-level loop filter offsets (LoopFilterOffsetInPPS and LoopFilterDisable must be 0)
-
-#=========== Misc. ============
-InternalBitDepth              : 10          # codec operating bit-depth
-
-#=========== Coding Tools =================
-SAO                           : 1           # Sample adaptive offset  (0: OFF, 1: ON)
-TransformSkip                 : 1           # Transform skipping (0: OFF, 1: ON)
-TransformSkipFast             : 1           # Fast Transform skipping (0: OFF, 1: ON)
-TransformSkipLog2MaxSize      : 5
-SAOLcuBoundary                : 0           # SAOLcuBoundary using non-deblocked pixels (0: OFF, 1: ON)
-
-#============ Tiles / Slices ================
-EnablePicPartitioning         : 1                      # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
-TileColumnWidthArray          : 1 2 3 4                # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
-TileRowHeightArray            : 1 2 3 4                # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
-RasterScanSlices              : 1                      # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
-RasterSliceSizes              : 1                      # Raster-scan slice sizes in units of tiles. Last slice size will be repeated uniformly to cover any remaining tiles in the picture
-DisableLoopFilterAcrossTiles  : 0                      # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
-DisableLoopFilterAcrossSlices : 0                      # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
-
-#============ Rate Control ======================
-RateControl                         : 0                # Rate control: enable rate control
-TargetBitrate                       : 1000000          # Rate control: target bitrate, in bps
-KeepHierarchicalBit                 : 2                # Rate control: 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation
-LCULevelRateControl                 : 1                # Rate control: 1: LCU level RC; 0: picture level RC
-RCLCUSeparateModel                  : 1                # Rate control: use LCU level separate R-lambda model
-InitialQP                           : 0                # Rate control: initial QP
-RCForceIntraQP                      : 0                # Rate control: force intra QP to be equal to initial QP
-
-#============ VTM settings ======================
-LoopFilterTcOffset_div2             : 0
-SEIDecodedPictureHash               : 0
-CbQpOffset                          : 1
-CrQpOffset                          : 1
-
-ReWriteParamSets                    : 1
-#============ NEXT ====================
-
-# General
-CTUSize                      : 128
-LCTUFast                     : 1
-
-DualITree                    : 1      # separate partitioning of luma and chroma channels for I-slices
-MinQTLumaISlice              : 8
-MinQTChromaISliceInChromaSamples: 4      # minimum QT size in chroma samples for chroma separate tree
-MinQTNonISlice               : 8
-MaxMTTHierarchyDepth         : 3
-MaxMTTHierarchyDepthISliceL  : 3
-MaxMTTHierarchyDepthISliceC  : 3
-
-MTS                          : 1
-MTSIntraMaxCand              : 3
-MTSInterMaxCand              : 4
-SBT                          : 1
-LFNST			     : 1
-ISP                          : 1
-MMVD                         : 1
-Affine                       : 1
-SubPuMvp                     : 1
-MaxNumMergeCand              : 6
-LMChroma                     : 1      # use CCLM only
-DepQuant                     : 1
-IMV                          : 1
-ALF                          : 1
-BCW                          : 1 
-BcwFast                      : 1
-BIO                          : 1 
-CIIP                         : 1
-Triangle                     : 1
-IBC                          : 0      # turned off in CTC
-AllowDisFracMMVD             : 1
-AffineAmvr                   : 1
-LMCSEnable                   : 1      # LMCS: 0: disable, 1:enable
-LMCSSignalType               : 0      # Input signal type: 0:SDR, 1:HDR-PQ, 2:HDR-HLG
-LMCSUpdateCtrl               : 0      # LMCS model update control: 0:RA, 1:AI, 2:LDB/LDP
-MRL                          : 1
-MIP                          : 1
-DMVR                         : 1
-SMVD                         : 1
-
-# Fast tools
-PBIntraFast                  : 1
-ISPFast                      : 1
-FastMrg                      : 1
-AMaxBT                       : 1
-FastMIP                      : 0
-FastLFNST		     : 0
-
-# Encoder optimization tools
-AffineAmvrEncOpt             : 1
-MmvdDisNum		     : 6
-### DO NOT ADD ANYTHING BELOW THIS LINE ###
-### DO NOT DELETE THE EMPTY LINE BELOW ###
-
-
-
diff --git a/cfg/partitioning/raster_slice.cfg b/cfg/partitioning/raster_slice.cfg
new file mode 100644
index 000000000..11f9f2a5e
--- /dev/null
+++ b/cfg/partitioning/raster_slice.cfg
@@ -0,0 +1,13 @@
+# example configuration file for raster scan slices
+# to be used in combination with a CTC and sequence configuration file
+# contains 12 tiles and 3 raster-scan slices
+
+#============ Tiles / Slices ================
+EnablePicPartitioning         : 1                      # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
+
+TileColumnWidthArray          : 6 6 6                  # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
+TileRowHeightArray            : 3 3 3 3                # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
+RasterScanSlices              : 1                      # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
+RasterSliceSizes              : 2 5 5                  # Raster-scan slice sizes in units of tiles. Last slice size will be repeated uniformly to cover any remaining tiles in the picture
+DisableLoopFilterAcrossTiles  : 0                      # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
+DisableLoopFilterAcrossSlices : 0                      # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
diff --git a/cfg/partitioning/raster_slice_1_slice_per_tile.cfg b/cfg/partitioning/raster_slice_1_slice_per_tile.cfg
new file mode 100644
index 000000000..d582ec990
--- /dev/null
+++ b/cfg/partitioning/raster_slice_1_slice_per_tile.cfg
@@ -0,0 +1,11 @@
+# example configuration file for raster scan slices with a single slice per tile
+# to be used in combination with a CTC and sequence configuration file
+
+#============ Tiles / Slices ================
+EnablePicPartitioning         : 1                      # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
+TileColumnWidthArray          : 1 2 3 4                # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
+TileRowHeightArray            : 1 2 3 4                # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
+RasterScanSlices              : 1                      # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
+RasterSliceSizes              : 1                      # Raster-scan slice sizes in units of tiles. Last slice size will be repeated uniformly to cover any remaining tiles in the picture
+DisableLoopFilterAcrossTiles  : 0                      # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
+DisableLoopFilterAcrossSlices : 0                      # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
diff --git a/cfg/nonCTC-SliceConfigExamples/encoder_rectangular_slice_classB.cfg b/cfg/partitioning/rect_slice_classB.cfg
similarity index 88%
rename from cfg/nonCTC-SliceConfigExamples/encoder_rectangular_slice_classB.cfg
rename to cfg/partitioning/rect_slice_classB.cfg
index 7081049c1..4bbc81840 100644
--- a/cfg/nonCTC-SliceConfigExamples/encoder_rectangular_slice_classB.cfg
+++ b/cfg/partitioning/rect_slice_classB.cfg
@@ -1,16 +1,13 @@
+# example configuration file for rectangular slices
+# to be used in combination with a CTC and sequence configuration file
+# contains 4 tiles and 4 rectangular slices
+
 #============ Tiles / Slices ================
 EnablePicPartitioning         : 1                         # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
 
-# Figure 6 - Section 6.3.1 - 4 tiles and 4 rectangular slices
 TileColumnWidthArray          : 7 8                       # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
 TileRowHeightArray            : 4 5                       # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
 RasterScanSlices              : 0                         # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
 RectSlicePositions            : 0 126 7 29 37 59 67 134   # Rectangular slice positions. List containing pairs of top-left CTU RS address followed by bottom-right CTU RS address
 DisableLoopFilterAcrossTiles  : 0                         # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
 DisableLoopFilterAcrossSlices : 0                         # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
-
-### DO NOT ADD ANYTHING BELOW THIS LINE ###
-### DO NOT DELETE THE EMPTY LINE BELOW ###
-
-
-
diff --git a/cfg/partitioning/rect_slice_fixed_size.cfg b/cfg/partitioning/rect_slice_fixed_size.cfg
new file mode 100644
index 000000000..9f00a45da
--- /dev/null
+++ b/cfg/partitioning/rect_slice_fixed_size.cfg
@@ -0,0 +1,14 @@
+# example configuration file for rectangular slices
+# to be used in combination with a CTC and sequence configuration file
+# contains 24 tiles and 6 rectangular slices
+
+#============ Tiles / Slices ================
+EnablePicPartitioning         : 1                         # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
+
+TileColumnWidthArray          : 3 3 3 3 3 3               # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
+TileRowHeightArray            : 3 3 3 3                   # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
+RasterScanSlices              : 0                         # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
+RectSliceFixedWidth           : 2                         # Fixed rectangular slice width in units of tiles (0: disable this feature and use RectSlicePositions instead)
+RectSliceFixedHeight          : 2                         # Fixed rectangular slice height in units of tiles (0: disable this feature and use RectSlicePositions instead)
+DisableLoopFilterAcrossTiles  : 0                         # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
+DisableLoopFilterAcrossSlices : 0                         # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
diff --git a/cfg/partitioning/subpicture_3_slice_2_tile.cfg b/cfg/partitioning/subpicture_3_slice_2_tile.cfg
new file mode 100644
index 000000000..bd0453de1
--- /dev/null
+++ b/cfg/partitioning/subpicture_3_slice_2_tile.cfg
@@ -0,0 +1,38 @@
+# example cfg file, assuming an 832x480 input sequence with CTU size = 128x128, and split to 2 tiles, with two tile columns and one tile row.
+# example 2 tiles, 3 subpictures in a 832x480 picture:
+#----------
+#|    |   |
+#|    |   |
+#|    |---|
+#|    |   |
+#|    |   |
+#----------
+#     |
+#     v
+# vertically divided into 2 tile, the second tile include two subpicture/slices
+
+SubPicInfoPresentFlag                  	: 1             # subpicture information present flag(0: OFF, 1: ON)
+NumSubPics                              : 3             # number of subpictures in a picture
+SubPicCtuTopLeftX                     	: 0 4 4         # specifies horizontal position of top left CTU of i-th subpicture in unit of CtbSizeY 
+SubPicCtuTopLeftY                       : 0 0 2         # specifies vertical position of top left CTU of i-th subpicture in unit of CtbSizeY
+SubPicWidth                             : 4 3 3         # specifies the width of the i-th subpicture in units of CtbSizeY
+SubPicHeight                            : 4 2 2         # specifies the height of the i-th subpicture in units of CtbSizeY
+SubPicTreatedAsPicFlag                  : 1 1 1         # equal to 1 specifies that the i-th subpicture of each coded picture in the CLVS is treated as a picture in the decoding process excluding in-loop filtering operations
+LoopFilterAcrossSubpicEnabledFlag       : 0 0 1         # equal to 1 specifies that in-loop filtering operations may be performed across the boundaries of the i-th subpicture in each coded picture in the CLVS
+SubPicIdMappingExplicitlySignalledFlag  : 0             # equal to 1 specifies that the subpicture ID mapping is explicitly signalled, either in the SPS or in the PPSs
+SubPicIdMappingInSpsFlag                : 0             # specifies that subpicture ID mapping is signalled in the SPS(0: OFF, 1: ON)
+SubPicIdLen                             : 0             # the number of bits used to represent the syntax element sps_subpic_id[ i ]
+SubPicId                                : 0             # subpicture ID of the i-th subpicture
+
+
+#============ Tiles / Slices ================
+EnablePicPartitioning         : 1                       # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
+
+TileColumnWidthArray          : 4                       # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
+TileRowHeightArray            : 4                       # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
+RasterScanSlices              : 0                       # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
+RectSliceFixedWidth           : 0                       # Fixed rectangular slice width in units of tiles (0: disable this feature and use RectSlicePositions instead)
+RectSliceFixedHeight          : 0                       # Fixed rectangular slice height in units of tiles (0: disable this feature and use RectSlicePositions instead)
+RectSlicePositions            : 0 24 4 13 18 27
+DisableLoopFilterAcrossTiles  : 0                       # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
+DisableLoopFilterAcrossSlices : 0                       # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
diff --git a/cfg/partitioning/subpicture_3_slice_2_tile_1_slice_per_subpic.cfg b/cfg/partitioning/subpicture_3_slice_2_tile_1_slice_per_subpic.cfg
new file mode 100644
index 000000000..4c405d69e
--- /dev/null
+++ b/cfg/partitioning/subpicture_3_slice_2_tile_1_slice_per_subpic.cfg
@@ -0,0 +1,39 @@
+# example cfg file, assuming an 832x480 input sequence with CTU size = 128x128, and split to 2 tiles, with two tile columns and one tile row.
+# example 2 tiles, 3 subpictures (and each subpicture is a slice) in a 832x480 picture:
+#----------
+#|    |   |
+#|    |   |
+#|    |---|
+#|    |   |
+#|    |   |
+#----------
+#     |
+#     v
+# vertically divided into 2 tile, the second tile include two subpicture/slices
+
+SubPicInfoPresentFlag                  	: 1             # subpicture information present flag(0: OFF, 1: ON)
+NumSubPics                              : 3             # number of subpictures in a picture
+SubPicCtuTopLeftX                     	: 0 4 4         # specifies horizontal position of top left CTU of i-th subpicture in unit of CtbSizeY 
+SubPicCtuTopLeftY                       : 0 0 2         # specifies vertical position of top left CTU of i-th subpicture in unit of CtbSizeY
+SubPicWidth                             : 4 3 3         # specifies the width of the i-th subpicture in units of CtbSizeY
+SubPicHeight                            : 4 2 2         # specifies the height of the i-th subpicture in units of CtbSizeY
+SubPicTreatedAsPicFlag                  : 1 1 1         # equal to 1 specifies that the i-th subpicture of each coded picture in the CLVS is treated as a picture in the decoding process excluding in-loop filtering operations
+LoopFilterAcrossSubpicEnabledFlag       : 0 0 0         # equal to 1 specifies that in-loop filtering operations may be performed across the boundaries of the i-th subpicture in each coded picture in the CLVS
+SubPicIdMappingExplicitlySignalledFlag  : 0             # equal to 1 specifies that the subpicture ID mapping is explicitly signalled, either in the SPS or in the PPSs
+SubPicIdMappingInSpsFlag                : 0             # specifies that subpicture ID mapping is signalled in the SPS(0: OFF, 1: ON)
+SubPicIdLen                             : 0             # the number of bits used to represent the syntax element sps_subpic_id[ i ]
+SubPicId                                : 0             # subpicture ID of the i-th subpicture
+
+
+#============ Tiles / Slices ================
+EnablePicPartitioning         : 1                       # Enable picture partitioning (0: single tile, single slice, 1: multiple tiles/slices can be used)
+SingleSlicePerSubpic : 1
+
+TileColumnWidthArray          : 4                       # Tile column widths in units of CTUs. Last column width will be repeated uniformly to cover any remaining picture width
+TileRowHeightArray            : 4                       # Tile row heights in units of CTUs. Last row height will be repeated uniformly to cover any remaining picture height  
+RasterScanSlices              : 0                       # Raster-scan or rectangular slices (0: rectangular, 1: raster-scan)
+RectSliceFixedWidth           : 0                       # Fixed rectangular slice width in units of tiles (0: disable this feature and use RectSlicePositions instead)
+RectSliceFixedHeight          : 0                       # Fixed rectangular slice height in units of tiles (0: disable this feature and use RectSlicePositions instead)
+RectSlicePositions            : 0 24 4 13 18 27
+DisableLoopFilterAcrossTiles  : 0                       # Loop filtering (DBLK/SAO/ALF) applied across tile boundaries or not (0: filter across tile boundaries  1: do not filter across tile boundaries)
+DisableLoopFilterAcrossSlices : 0                       # Loop filtering (DBLK/SAO/ALF) applied across slice boundaries or not (0: filter across slice boundaries 1: do not filter across slice boundaries)
diff --git a/cfg/nonCTC-SliceConfigExamples/subpicture_4Slice2HorSubPic.cfg b/cfg/partitioning/subpicture_4_slice_2_hor_subpic.cfg
similarity index 100%
rename from cfg/nonCTC-SliceConfigExamples/subpicture_4Slice2HorSubPic.cfg
rename to cfg/partitioning/subpicture_4_slice_2_hor_subpic.cfg
diff --git a/cfg/nonCTC-SliceConfigExamples/subpicture_4Slice2VerSubPic.cfg b/cfg/partitioning/subpicture_4_slice_2_ver_subpic.cfg
similarity index 100%
rename from cfg/nonCTC-SliceConfigExamples/subpicture_4Slice2VerSubPic.cfg
rename to cfg/partitioning/subpicture_4_slice_2_ver_subpic.cfg
diff --git a/cfg/nonCTC-SliceConfigExamples/TwoSubpictures_with_EightSlices.cfg b/cfg/partitioning/subpicture_8_slice_12_tile_2_subpic.cfg
similarity index 97%
rename from cfg/nonCTC-SliceConfigExamples/TwoSubpictures_with_EightSlices.cfg
rename to cfg/partitioning/subpicture_8_slice_12_tile_2_subpic.cfg
index 3371a0a7b..8cf2372e5 100644
--- a/cfg/nonCTC-SliceConfigExamples/TwoSubpictures_with_EightSlices.cfg
+++ b/cfg/partitioning/subpicture_8_slice_12_tile_2_subpic.cfg
@@ -1,8 +1,5 @@
 # example cfg file, assuming an 1920x1080 input sequence with CTU size = 128x128, and split to 8 rectangular slices, 12 tiles and 2 subpictures
 
-SourceWidth                             : 1920
-SourceHeight                            : 1080
-
 SubPicInfoPresentFlag                   : 1             # subpicture information present flag(0: OFF, 1: ON)
 NumSubPics                              : 2             # number of subpictures in a picture
 SubPicCtuTopLeftX                       : 0 11           # specifies horizontal position of top left CTU of i-th subpicture in unit of CtbSizeY 
-- 
GitLab