cat-cfs / twobilliontoolkit

This repo stands as a singular place for all the tools that will be developed for the processing of 2 Billion Trees data and information
MIT License
1 stars 0 forks source link

Record Reviser GDB Updates #2

Closed nesdolya closed 6 months ago

nesdolya commented 7 months ago

I ran spatial transformer on the data I shared with you earlier, and found that the content of the GDB matched exactly expected project_spatial_id for records in the database version of the raw_data_tracker (i.e. in_raw_gdb == True).

When I run the records reviser using a script I wrote at the link below, the names of the feature classes in the GDB are not updated to match the new project_spatial_id, but when I manually change the records in the record reviser GUI the feature class name in the GDB does change. Please let me know if I am missing a step on my end (in the below script) or if you have any questions. Perhaps, there is a bug preventing the renaming of the feature classes when called from the script?

\vic-fas1\projects_a\2BT\02_Tools\spatial_data_processing_workflow\run_record_reviser.py I coped the call to the records reviser that would be used if the user provided a change_dict.

AnthonyRodway commented 7 months ago

Did you pass the gdb path to the update_recods function? image also I am not sure if you changed it but gdb still equals 'path/to/gdb'

nesdolya commented 7 months ago

Thanks, I did miss that. I'll rerun!

nesdolya commented 7 months ago

When I ran RecordsReviser using the --change command, the GDB was not updated to match the change. 0000_XXX_000_04 should be 2022_CAT_025_16 in the GDB (image 2 is the GDB after running the below command). I think line 430 in records_reviser.py should be updated to include the GDB path based on your above comment?

image

image

AnthonyRodway commented 7 months ago

yep it definitely should, my bad good catch

AnthonyRodway commented 7 months ago

👍 https://github.com/cat-cfs/twobilliontoolkit/commit/7b3a00389a042b7254b3d931ccf6aab756404125