Skip to content

Commit

Permalink
chore(deps): update to pybsm 0.10.2 and nrtk 0.19.1
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulHax committed Jan 20, 2025
1 parent 9346324 commit f334aec
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ dependencies = [
"accelerate",
"numpy",
"Pillow",
"pybsm>=0.6,<=0.9.0",
"pybsm==0.10.2",
"scikit-learn>=1.6.0",
"smqtk_image_io",
"tabulate",
Expand All @@ -42,7 +42,7 @@ dependencies = [
"transformers",
"datasets[vision]",
"umap-learn",
"nrtk[headless]>=0.12.0,<=0.16.0",
"nrtk[headless]==0.19.1",
"trame-annotations>=0.4.0",
"kwcoco",
]
Expand Down
1 change: 0 additions & 1 deletion src/nrtk_explorer/app/transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
from trame_server import Server

import nrtk_explorer.library.transforms as trans
import nrtk_explorer.library.nrtk_transforms as nrtk_trans
import nrtk_explorer.library.yaml_transforms as nrtk_yaml
from nrtk_explorer.library import object_detector
from nrtk_explorer.library.app_config import process_config
Expand Down
4 changes: 2 additions & 2 deletions src/nrtk_explorer/library/nrtk_transforms.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,10 @@ nrtk_pybsm_detector_otf:
type: float
label: Focal length (m)

nrtk_pybsm_2:
nrtk_pybsm:
perturber: nrtk.impls.perturb_image.pybsm.perturber.PybsmPerturber
perturber_kwargs: nrtk_explorer.library.nrtk_transforms.create_sample_sensor_and_scenario
exec_default_args: [{ img_gsd: 0.15 }]
exec_default_args: [None, { img_gsd: 0.15 }]
description:
D:
_path: [sensor, D]
Expand Down
2 changes: 1 addition & 1 deletion src/nrtk_explorer/library/yaml_transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,6 @@ def execute(self, input, *input_args):
input_args = self.exec_args

input_array = np.asarray(input)
output_array = self._perturber.perturb(input_array, *input_args)
output_array, _ = self._perturber.perturb(input_array, *input_args)

return ImageModule.fromarray(output_array)
2 changes: 1 addition & 1 deletion tests/test_transforms.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ def test_gaussian_blur():

def test_pybsm():
transforms = generate_transforms()
pybsm = transforms["nrtk_pybsm_2"]()
pybsm = transforms["nrtk_pybsm"]()
pybsm.set_parameters({"D": 0.25, "f": 4.0})
pybsm.execute(get_image())

0 comments on commit f334aec

Please sign in to comment.