Skip to content

Conversation

@GwenaelleSa
Copy link
Member

@GwenaelleSa GwenaelleSa commented Oct 17, 2024

  • Add category file in the config of the examples
  • Change the crs for the original image path in the detection attributes
  • Remove the control that there are the same number of class in every coco file, all categories are always saved to the "categories" part of the COCO files, independently of the categories present among labels.
  • Add possibility to assess results with a predefined confidence score.

@GwenaelleSa
Copy link
Member Author

This PR is part of the conclusion of the project on border points.

@GwenaelleSa GwenaelleSa marked this pull request as draft October 17, 2024 10:04
@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

@GwenaelleSa GwenaelleSa marked this pull request as ready for review October 17, 2024 15:29
@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

@GwenaelleSa
Copy link
Member Author

@cleherny @acerioni
The PR is updated with master and ready for review.

@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

@stdl-s-sonarqube

This comment has been minimized.

Copy link
Contributor

@cleherny cleherny left a comment

Choose a reason for hiding this comment

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

Still few modification to do but it's almost done!

# we can mimick ESRI MapImageLayer's metadata,
# at least the section that we need
image_metadata = {
"year": year,
Copy link
Contributor

@cleherny cleherny Nov 26, 2024

Choose a reason for hiding this comment

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

To prevent a bug due to 'year' value being filled with None in case no year is provided, I propose to replace this line with:
**({'year': year} if year else {}),
then the key year will be added only if it exists. Then changes made l783 in generate_tilesets.py can be deleted.

img_md_df.rename(columns={"index": "img_file"}, inplace=True)

img_md_df['id'] = img_md_df.apply(misc.img_md_record_to_tile_id, axis=1)
if img_md_df.year.isna().all():
Copy link
Contributor

@cleherny cleherny Nov 26, 2024

Choose a reason for hiding this comment

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

Those lines provoke an error when the WMS or MIL connectors are selected. I rather propose to modify the way the FOLDER metadata is built (see l107 FOLDER.py) and delete these lines.

tiles_gdf=aoi_tiles_gdf.to_crs(IM_SOURCE_SRS), # <- note the reprojection
base_path=IM_SOURCE_LOCATION,
end_path=ALL_IMG_PATH,
year=YEAR,
Copy link
Contributor

Choose a reason for hiding this comment

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

This line must be preserved. I think we lost it in the previous PR merge...

@GwenaelleSa GwenaelleSa requested a review from cleherny November 27, 2024 08:51
@stdl-s-sonarqube
Copy link

Passed

Analysis Details

0 Issues

  • Bug 0 Bugs
  • Vulnerability 0 Vulnerabilities
  • Code Smell 0 Code Smells

Coverage and Duplications

  • Coverage No coverage information (0.00% Estimated after merge)
  • Duplications 0.00% Duplicated Code (0.00% Estimated after merge)

Project ID: swiss-territorial-data-lab_object-detector_AYZ4zWIzr7JdaaSXwexc

View in SonarQube

Copy link
Contributor

@cleherny cleherny left a comment

Choose a reason for hiding this comment

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

I haven't re-run the scripts but it looks all good to me. Thank you!

@GwenaelleSa GwenaelleSa merged commit 13772c1 into master Nov 27, 2024
1 check passed
@GwenaelleSa GwenaelleSa deleted the gs/code_improvement branch November 27, 2024 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants