mirror of
https://github.com/Dictionarry-Hub/database.git
synced 2025-12-11 08:17:02 +00:00
fix(format): HDR improvements (#50)
- fixed a issue where HDR was matching both HDR10 & 10+ - fixed an issue where unknown lossless audio was matching for TrueHD releases / missing groups - added a new 'general HDR' CF which matches HDR that isn't HDR10 nor HDR10+ - added an optional any character between HDR10 and +
This commit is contained in:
95
regex_patterns/HDR.yml
Normal file
95
regex_patterns/HDR.yml
Normal file
@@ -0,0 +1,95 @@
|
||||
name: HDR
|
||||
pattern: \b(HDR)\b
|
||||
description: 'This regex matches a `HDR` generalisation. This can be HDR10, HDR10+,
|
||||
etc. '
|
||||
tags:
|
||||
- Enhancement
|
||||
- Colour Grade
|
||||
- HDR
|
||||
tests:
|
||||
- expected: true
|
||||
id: 2
|
||||
input: HDR+
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan:
|
||||
end: 3
|
||||
start: 0
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- HDR
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 3
|
||||
input: HDR10
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 4
|
||||
input: HDR10+
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 8
|
||||
input: HDR10
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: true
|
||||
id: 9
|
||||
input: Barbie (2023) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR TrueHD Atmos 7.1
|
||||
English-FraMeSToR
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan:
|
||||
end: 55
|
||||
start: 52
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- HDR
|
||||
passes: true
|
||||
- expected: true
|
||||
id: 10
|
||||
input: Game of Thrones (2011) S06 2160p UHD BluRay REMUX HEVC DV HDR TrueHD Atmos
|
||||
7.1 English-FraMeSToR
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan:
|
||||
end: 61
|
||||
start: 58
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- HDR
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 11
|
||||
input: Liu lang di qiu 2 AKA The Wandering Earth II 2023 2160p CHN UHD Blu-ray DoVi
|
||||
HDR10 HEVC TrueHD 7.1 Atmos-ANKO
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 12
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10+ TrueHD
|
||||
Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 13
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10P TrueHD
|
||||
Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2025-04-03T04:14:14.836165'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
@@ -1,10 +1,7 @@
|
||||
name: HDR10+
|
||||
pattern: (?<=^(?!.*\b(HLG|PQ|SDR)(\b|\d)).*?)HDR10(\+|P(lus)?)
|
||||
description: This regex matches "HDR10" when followed by either a plus sign ("+"),
|
||||
"P", or "Plus", but only in strings that don't contain "HLG", "PQ", or "SDR" (when
|
||||
followed by either a word boundary or digit) anywhere in the text. In other words,
|
||||
it finds references to HDR10+ or HDR10Plus variants while excluding strings that
|
||||
mention other HDR-related technologies.
|
||||
pattern: \bHDR10.?(\+|P(lus)?\b)
|
||||
description: This regex matches `HDR10` when followed by either a plus sign `+`, `P`,
|
||||
or `Plus`
|
||||
tags:
|
||||
- Enhancement
|
||||
- Colour Grade
|
||||
@@ -13,7 +10,7 @@ tests:
|
||||
- expected: false
|
||||
id: 1
|
||||
input: HDR
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -21,7 +18,7 @@ tests:
|
||||
- expected: false
|
||||
id: 2
|
||||
input: HDR+
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -29,7 +26,7 @@ tests:
|
||||
- expected: false
|
||||
id: 3
|
||||
input: HDR10
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -37,21 +34,19 @@ tests:
|
||||
- expected: true
|
||||
id: 4
|
||||
input: HDR10+
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 6
|
||||
start: 0
|
||||
matchedContent: HDR10+
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- +
|
||||
- null
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 5
|
||||
input: HLG HDR
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -59,7 +54,7 @@ tests:
|
||||
- expected: false
|
||||
id: 6
|
||||
input: SDR HDR
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -67,7 +62,7 @@ tests:
|
||||
- expected: false
|
||||
id: 7
|
||||
input: PQ HDR
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -75,28 +70,24 @@ tests:
|
||||
- expected: true
|
||||
id: 8
|
||||
input: HDR10P
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 6
|
||||
start: 0
|
||||
matchedContent: HDR10P
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- P
|
||||
- null
|
||||
passes: true
|
||||
- expected: true
|
||||
id: 9
|
||||
input: HDR10Plus
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 9
|
||||
start: 0
|
||||
matchedContent: HDR10Plus
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- Plus
|
||||
- lus
|
||||
passes: true
|
||||
@@ -104,14 +95,12 @@ tests:
|
||||
id: 10
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10+ TrueHD
|
||||
Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 68
|
||||
start: 62
|
||||
matchedContent: HDR10+
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- +
|
||||
- null
|
||||
passes: true
|
||||
@@ -119,14 +108,12 @@ tests:
|
||||
id: 11
|
||||
input: La Maison S01 REPACK 2160p ATVP WEB-DL Dual-Audio DD+ 5.1 Atmos DV HDR10+
|
||||
H.265-Kitsune
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 73
|
||||
start: 67
|
||||
matchedContent: HDR10+
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- +
|
||||
- null
|
||||
passes: true
|
||||
@@ -134,8 +121,21 @@ tests:
|
||||
id: 12
|
||||
input: Liu lang di qiu 2 AKA The Wandering Earth II 2023 2160p CHN UHD Blu-ray DoVi
|
||||
HDR10 HEVC TrueHD 7.1 Atmos-ANKO
|
||||
lastRun: '2024-12-13T09:52:40.529508'
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: true
|
||||
id: 13
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10 Plus
|
||||
TrueHD Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2025-04-05T09:25:21.372205'
|
||||
matchSpan:
|
||||
end: 72
|
||||
start: 62
|
||||
matchedContent: HDR10 Plus
|
||||
matchedGroups:
|
||||
- Plus
|
||||
- lus
|
||||
passes: true
|
||||
|
||||
@@ -1,36 +1,16 @@
|
||||
name: HDR10
|
||||
pattern: (?<=^(?!.*\b(HLG|PQ|SDR)(\b|\d)).*?)HDR(?!((10)?(\+|P(lus)?)))
|
||||
description: This regex matches "HDR" only in strings that do not contain "HLG", "PQ",
|
||||
or "SDR" (when followed by either a word boundary or digit) anywhere in the text,
|
||||
and where the "HDR" itself is not followed by any HDR format specifiers like "10+",
|
||||
"+", "10P", "P", "10Plus", or "Plus". It ensures we're matching standalone "HDR"
|
||||
references that aren't tied to any specific HDR format or appearing in strings that
|
||||
mention other common HDR-related technologies.
|
||||
pattern: \bHDR10(?!\+|Plus)\b
|
||||
description: 'This regex matches `HDR10` only when it *is not* followed by any HDR
|
||||
format specifiers like `+`, or `Plus`. '
|
||||
tags:
|
||||
- Enhancement
|
||||
- Colour Grade
|
||||
- HDR
|
||||
tests:
|
||||
- expected: true
|
||||
id: 1
|
||||
input: HDR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
matchSpan:
|
||||
end: 3
|
||||
start: 0
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 2
|
||||
input: HDR+
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -38,23 +18,17 @@ tests:
|
||||
- expected: true
|
||||
id: 3
|
||||
input: HDR10
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan:
|
||||
end: 3
|
||||
end: 5
|
||||
start: 0
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
matchedContent: HDR10
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 4
|
||||
input: HDR10+
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -62,7 +36,7 @@ tests:
|
||||
- expected: false
|
||||
id: 5
|
||||
input: HLG HDR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -70,7 +44,7 @@ tests:
|
||||
- expected: false
|
||||
id: 6
|
||||
input: SDR HDR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -78,7 +52,7 @@ tests:
|
||||
- expected: false
|
||||
id: 7
|
||||
input: PQ HDR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
@@ -86,75 +60,56 @@ tests:
|
||||
- expected: true
|
||||
id: 8
|
||||
input: HDR10
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan:
|
||||
end: 3
|
||||
end: 5
|
||||
start: 0
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
matchedContent: HDR10
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: true
|
||||
- expected: false
|
||||
id: 9
|
||||
input: Barbie (2023) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR TrueHD Atmos 7.1
|
||||
English-FraMeSToR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
matchSpan:
|
||||
end: 55
|
||||
start: 52
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: true
|
||||
- expected: false
|
||||
id: 10
|
||||
input: Game of Thrones (2011) S06 2160p UHD BluRay REMUX HEVC DV HDR TrueHD Atmos
|
||||
7.1 English-FraMeSToR
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
matchSpan:
|
||||
end: 61
|
||||
start: 58
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: true
|
||||
id: 11
|
||||
input: Liu lang di qiu 2 AKA The Wandering Earth II 2023 2160p CHN UHD Blu-ray DoVi
|
||||
HDR10 HEVC TrueHD 7.1 Atmos-ANKO
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan:
|
||||
end: 80
|
||||
end: 82
|
||||
start: 77
|
||||
matchedContent: HDR
|
||||
matchedGroups:
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
- null
|
||||
matchedContent: HDR10
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 12
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10+ TrueHD
|
||||
Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2024-12-13T09:52:16.317820'
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
passes: true
|
||||
- expected: false
|
||||
id: 13
|
||||
input: Schindler's List (1993) 2160p UHD BluRay Hybrid REMUX HEVC DV HDR10P TrueHD
|
||||
Atmos 7.1 English-WiLDCAT
|
||||
lastRun: '2025-04-02T20:01:38.732592'
|
||||
matchSpan: null
|
||||
matchedContent: null
|
||||
matchedGroups: []
|
||||
|
||||
Reference in New Issue
Block a user