Skip to content

Commit

Permalink
Merge pull request #662 from roboflow/fix/blur-and-pixelate-base-class
Browse files Browse the repository at this point in the history
Switch base class of blur and pixelate to PredictionsVisualizationManifest / PredictionsVisualizationBlock
  • Loading branch information
grzegorz-roboflow authored Sep 19, 2024
2 parents 947ebbf + c75f881 commit 1236205
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions inference/core/workflows/core_steps/visualizations/blur/v1.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from inference.core.workflows.core_steps.visualizations.common.base import (
OUTPUT_IMAGE_KEY,
VisualizationBlock,
VisualizationManifest,
PredictionsVisualizationBlock,
PredictionsVisualizationManifest,
)
from inference.core.workflows.execution_engine.entities.base import WorkflowImageData
from inference.core.workflows.execution_engine.entities.types import (
Expand All @@ -23,7 +23,7 @@
"""


class BlurManifest(VisualizationManifest):
class BlurManifest(PredictionsVisualizationManifest):
type: Literal[f"{TYPE}", "BlurVisualization"]
model_config = ConfigDict(
json_schema_extra={
Expand All @@ -47,7 +47,7 @@ def get_execution_engine_compatibility(cls) -> Optional[str]:
return ">=1.0.0,<2.0.0"


class BlurVisualizationBlockV1(VisualizationBlock):
class BlurVisualizationBlockV1(PredictionsVisualizationBlock):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.annotatorCache = {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

from inference.core.workflows.core_steps.visualizations.common.base import (
OUTPUT_IMAGE_KEY,
VisualizationBlock,
VisualizationManifest,
PredictionsVisualizationBlock,
PredictionsVisualizationManifest,
)
from inference.core.workflows.execution_engine.entities.base import WorkflowImageData
from inference.core.workflows.execution_engine.entities.types import (
Expand All @@ -23,7 +23,7 @@
"""


class PixelateManifest(VisualizationManifest):
class PixelateManifest(PredictionsVisualizationManifest):
type: Literal[f"{TYPE}", "PixelateVisualization"]
model_config = ConfigDict(
json_schema_extra={
Expand All @@ -47,7 +47,7 @@ def get_execution_engine_compatibility(cls) -> Optional[str]:
return ">=1.0.0,<2.0.0"


class PixelateVisualizationBlockV1(VisualizationBlock):
class PixelateVisualizationBlockV1(PredictionsVisualizationBlock):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.annotatorCache = {}
Expand Down

0 comments on commit 1236205

Please sign in to comment.