Skip to content

Commit

Permalink
Refactor image input handling in QuickOutput components
Browse files Browse the repository at this point in the history
  • Loading branch information
amirnd51 committed Jul 24, 2024
1 parent b20822a commit 8056002
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default function ImageEnhancement(props) {
<SingleColumnImageOutput
modelId={props.trial.model.id}
duration={props.trial.results.duration}
image={<ImageEnhancementImage input={props.trial.inputs[0]}
image={<ImageEnhancementImage input={props.trial.inputs[0].src}
feature={props.trial.results.responses[0].features[0]}/>}

/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export default function ObjectDetection(props) {
if (sections.length === 0) return <NoPredictions modelId={props.trial.model.id}/>

return <div className={getElement("top-row")}>
<ObjectDetectionImage img={props.trial.inputs[0]}
<ObjectDetectionImage img={props.trial.inputs[0].src}
filteredSections={filteredSections}
sections={sections}
hover={hover}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export default function useSemanticSegmentationControl(trial) {
labelToShow = feature?.semantic_segment.labels[hover.property] ?? "";
}

const image = trial.inputs[0];
const image = trial.inputs[0].src;
const {height, int_mask, labels, width} = feature?.semantic_segment ?? {
height: 0,
int_mask: [],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export default function ImageEnhancementSummary(props) {
return <div className={getBlock()}>
<div className={getElement("summary")}>
<div className={getElement("summary__content")}>
<ImageEnhancementImage input={props.trial.inputs[0]} feature={props.trial.results.responses[0].features[0]}/>
<ImageEnhancementImage input={props.trial.inputs[0].src} feature={props.trial.results.responses[0].features[0]}/>
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export default function ObjectDetectionSummary(props) {
<p className={getElement("header")}>Output:</p>

<div className={getElement("results")}>
<ObjectDetectionImage img={props.trial.inputs[0]}
<ObjectDetectionImage img={props.trial.inputs[0].src}
filteredSections={filteredSections}
hover={hover}
confidence={filter.confidence}
Expand Down

0 comments on commit 8056002

Please sign in to comment.