SELECT DISTINCT ?quickcategory WHERE {
# { ?file wdt:P4082 wd:Q28456857. } #Lumix GH5
#UNION
{ ?file wdt:P4082 wd:Q20889187. } #Lumix GX8
#UNION
#{ ?file wdt:P4082 wd:Q7130084. } #Lumix G3
#UNION
#{ ?file wdt:P4082 wd:Q1379717. } #Lumix G5
#UNION
#{ ?file wdt:P4082 wd:Q17049136. } #Lumix G6
# UNION
#{ ?file wdt:P4082 wd:Q20649008. } #Lumix G70
#UNION
#{ ?file wdt:P4082 wd:Q131703691. } #Lumix GH6
#UNION
#{ ?file wdt:P4082 wd:Q126387724. } #Lumix GH7
?file wdt:P2151 ?focalLength;
wdt:P6790 ?FStop;
wdt:P571 ?inception;
schema:contentUrl ?contentUrl.
# == Filters for focal length and F-stop ==
FILTER(?focalLength > 25 && ?focalLength < 36 )
FILTER(?FStop > 2.7 && ?FStop < 22.8)
#== Excluded lenses ==
MINUS { ?file wdt:P4082 wd:Q137719582. }
MINUS { ?file wdt:P4082 wd:Q28448747. } #OLYMPUS M.8mm F1.8
MINUS { ?file wdt:P4082 wd:Q7130076. }
MINUS { ?file wdt:P4082 wd:Q60785693. }
MINUS { ?file wdt:P4082 wd:Q137720097. }
MINUS { ?file wdt:P4082 wd:Q28448747. }
MINUS { ?file wdt:P4082 wd:Q137732732. }
MINUS { ?file wdt:P4082 wd:Q122851377. }
MINUS { ?file wdt:P4082 wd:Q137647033. }
MINUS { ?file wdt:P4082 wd:Q137650462. }
MINUS { ?file wdt:P4082 wd:Q137669364. }
MINUS { ?file wdt:P4082 wd:Q137718371. }
MINUS { ?file wdt:P4082 wd:Q24910294. }
MINUS { ?file wdt:P4082 wd:Q21175643. }
MINUS { ?file wdt:P4082 wd:Q7130075. }
MINUS { ?file wdt:P4082 wd:Q137735292. }
MINUS { ?file wdt:P4082 wd:Q137787473. } #OLYMPUS M.8-25mm F4.0
MINUS { ?file wdt:P4082 wd:Q116719316. } #OLYMPUS M.7-14mm F2.8
MINUS { ?file wdt:P4082 wd:Q137720165. } #Leica DG 10-25
MINUS { ?file wdt:P4082 wd:Q137737464. } #Leica DG 12 F1.4
MINUS { ?file wdt:P4082 wd:Q137669386. } #Lumix G X 12-35
MINUS { ?file wdt:P4082 wd:Q137796502. } #Leica DG 12-35
MINUS { ?file wdt:P4082 wd:Q137796333. } #Lumix G 12-60 F3.5-5.6
MINUS { ?file wdt:P4082 wd:Q116719314. } #OLYMPUS M.45mm F1.2
MINUS { ?file wdt:P4082 wd:Q137718304. } #OLYMPUS M.75mm F1.8
# == Excluded creators ==
?file p:P170 ?statement.
MINUS { ?statement pq:P2093 "Leonhard Lenz". }
MINUS { ?statement pq:P2093 "Andreas Eichler". }
MINUS { ?statement pq:P2093 "debsaslaw". }
MINUS { ?statement pq:P2093 "School of Media and Public Affairs at GWU". }
MINUS { ?statement pq:P2093 "Loloito78". }
MINUS { ?statement pq:P2093 "StefanBoonen1". }
MINUS { ?statement pq:P2093 "Rashed hajji al hajji". }
MINUS { ?statement pq:P2093 "Mark Dixon". }
MINUS { ?statement pq:P2093 "OtterBoyGVA". }
MINUS { ?statement pq:P2093 "TheNoxid". }
MINUS { ?statement pq:P2093 "Yves Tennevin". }
MINUS { ?statement pq:P2093 "Codingexperiences". }
MINUS { ?statement pq:P2093 "School Strike". }
MINUS { ?statement pq:P2093 "Guellouz Mehdi". }
MINUS { ?statement pq:P2093 "Sparktour". }
MINUS { ?statement pq:P2093 "Rolf Dietrich Brecher". } # no lens information
MINUS { ?statement pq:P2093 "Swirliehead". } # no lens information
MINUS { ?statement pq:P2093 "MiriamPschtto". } # no lens information
MINUS { ?statement pq:P2093 "Andy Beecroft". } # no lens information
MINUS { ?statement pq:P2093 "Shinmaebashi". } # no lens information
MINUS { ?statement pq:P2093 "Adsum Dixit". } # no lens information
MINUS { ?statement pq:P2093 "Jean-Jacques Lasmolles". } # no lens information
MINUS { ?statement pq:P2093 "Adalberto Cencetti". } # no lens information
MINUS { ?statement pq:P2093 "David Dixon". } # no lens information
MINUS { ?statement pq:P2093 "Santeri Viinamäki". } # no lens information
MINUS { ?statement pq:P2093 "KO KUYO". } # no lens information
MINUS { ?statement pq:P2093 "ChowJoe3". } # no lens information
MINUS { ?statement pq:P2093 "TyDieOfficial". } # no lens information
MINUS { ?statement pq:P2093 "Elcapitana1". } # no lens information
MINUS { ?statement pq:P2093 "The National Guard". } # no lens information
MINUS { ?statement pq:P2093 "Membeth". } # no lens information
{ ?statement pq:P2093 "Julian Paren". }
# == Create QuickCategory code ==
BIND(wikibase:decodeUri(STR(IRI(?contentUrl))) AS ?decodedUrl)
BIND(REPLACE(STR(?decodedUrl), "^.*/", "") AS ?filenameWithExt)
BIND(CONCAT("File:", ?filenameWithExt, "