Skip to content

Commit 4f7d817

Browse files
authored
Update index.html to assume hardware is CPU if not specified
After recent updates a number of databases are not shown during filtering because hardware is not specified. This change assume hardware is CPU when it's missing. Another option is to add hardware to all results, but that's 2K files and will be a larger change.
1 parent cc10485 commit 4f7d817

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,7 @@ <h2>Detailed Comparison</h2>
777777
const matches = data.filter(elem =>
778778
((selectors.tuned.yes && elem.tuned === "yes") || (selectors.tuned.no && elem.tuned === "no")) &&
779779
((selectors.opensource.yes && elem.proprietary === "no") || (selectors.opensource.no && elem.proprietary === "yes")) &&
780-
((selectors.hardware.cpu && elem.hardware === "cpu") || (selectors.hardware.gpu && elem.hardware === "gpu")));
780+
((selectors.hardware.cpu && (elem.hardware === "cpu" || !elem.hardware)) || (selectors.hardware.gpu && elem.hardware === "gpu")));
781781

782782
function apply(container, getValues) {
783783
const allowed = new Set(matches.flatMap(getValues).map(x => String(x)));
@@ -1083,7 +1083,7 @@ <h2>Detailed Comparison</h2>
10831083
elem.tags.filter(type => selectors.type[type]).length > 0 &&
10841084
((selectors.tuned.yes && elem.tuned === "yes") || (selectors.tuned.no && elem.tuned === "no")) &&
10851085
((selectors.opensource.yes && elem.proprietary === "no") || (selectors.opensource.no && elem.proprietary === "yes")) &&
1086-
((selectors.hardware.cpu && elem.hardware === "cpu") || (selectors.hardware.gpu && elem.hardware === "gpu"))
1086+
((selectors.hardware.cpu && (elem.hardware === "cpu" || !elem.hardware)) || (selectors.hardware.gpu && elem.hardware === "gpu"))
10871087
);
10881088

10891089
/// Filter out unreasonable entries

0 commit comments

Comments
 (0)