Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Job output transform #548

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
Open

Job output transform #548

wants to merge 16 commits into from

Conversation

OlivGruwe
Copy link

@OlivGruwe OlivGruwe commented Aug 8, 2023

fixes #18
fixes #100

Pour les conversions image, si GeoTiff, distinguo fait dans class Tiff

Direct Links in job output +
makefile +
tests
Testing transformer engine added
Remove requirements-trfm
Add to main requirements
Update requirements
Ajout Multi frame Images
@github-actions github-actions bot added ci/doc Issue related to documentation of the package ci/operations Related to CI operations (actions, execution, install, builds, etc.) ci/tests Tests of the package and features feature/oas Issues related to OpenAPI specifications. process/wps3 Issue related to WPS 3.x (REST-JSON) processes support labels Aug 9, 2023
Copy link
Collaborator

@fmigneault fmigneault left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a few linting issues that can be resolved automatically using the make fix[...] targets.
Validate as well using make check[...] targets any other flagged issues that might need some manual adjustments. I didn't comment on all of them.

I did not go in depth into the actual implementation of the transform functions.
I think there is a few tests missing to validate that the actual results from each transformation is valid (eg: pixel values from one format to another are properly rendered or expected text from one format to another is properly structured).

Makefile Outdated Show resolved Hide resolved
tests/smoke/docker-compose.smoke-test.yml Outdated Show resolved Hide resolved
# noqa: E241,E501
(uri_provider_jobs, Visibility.PUBLIC, self.user_admin_id, filter_service(public_jobs)), # noqa: E241,E501

] # type: List[Tuple[str, str, Union[None, int], List[Job]]]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revert auto-formating by your IDE here and above.

except Exception as e:
print(cmt + " -> " + wmt + " failed")
assert False, os.path.splitext(f)[1] + " -> " + f + " " + str(e)
pass
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary pass

Comment on lines 94 to 96



Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove extra lines

weaver/processes/builtin/__init__.py Outdated Show resolved Hide resolved
Retrieve the possible formats of an output job.
"""
job = get_job(request)
return get_job_possible_output_formats(job)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should do some kind of sd.JobTranformerSchema().deserialize(<body>) check before returning the contents to ensure they match the format of weaver/wps_restapi/examples/job_transformer.json

weaver/tranform/png2svg.py Outdated Show resolved Hide resolved
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add missing docstrings and typings.

self.file_path = file_path
self.cmt = current_media_type.lower()
self.wmt = wanted_media_type.lower()
self.output_path = self.file_path
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The output path needs to be modifiable (either from init arg, or modified after before the process/get calls.
More importantly, no additional files should be added under the original WPS outputs sub-directories, because their contents could be critical to the packing/detection of other apps in a workflow chain.
We need to consider the creation of some "sibling" directory next to the WPS-output-ID dir to avoid modifying the output checksums.

@github-actions github-actions bot added feature/job Issues related to job execution, reporting and logging. feature/quotation Issues related to quotation, billing and estimators. process/builtin Issue related to builtin application processes labels Sep 24, 2024
@Nazim-crim Nazim-crim self-assigned this Sep 24, 2024
@github-actions github-actions bot added the feature/cli Issues or features related to CLI operations. label Sep 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci/doc Issue related to documentation of the package ci/operations Related to CI operations (actions, execution, install, builds, etc.) ci/tests Tests of the package and features feature/cli Issues or features related to CLI operations. feature/job Issues related to job execution, reporting and logging. feature/oas Issues related to OpenAPI specifications. feature/quotation Issues related to quotation, billing and estimators. process/builtin Issue related to builtin application processes process/wps3 Issue related to WPS 3.x (REST-JSON) processes support
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support the various formats that can represent a GeoTIFF Support /results/{id} and /outputs/{id} routes
3 participants