-
Notifications
You must be signed in to change notification settings - Fork 61
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
Cartographer and PixPlot Image preview #400
base: master
Are you sure you want to change the base?
Conversation
…dataset results folder it's working on pixplot datasets and the new cartagrapher datasets by using there manifests and data subfolder!
idea being we can have a configurable cartographer and run default "image wall" settings
Still do not know why but nothing renders; even the atlas images!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some crashes I found when testing.
webtool/views/views_dataset.py
Outdated
@@ -24,6 +27,21 @@ | |||
|
|||
csv.field_size_limit(1024 * 1024 * 1024) | |||
|
|||
if app.logger.getEffectiveLevel() == 10: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this still need to be here? It crashes (since time
is not imported)
webtool/views/views_dataset.py
Outdated
@@ -401,10 +479,12 @@ def show_result(key): | |||
:param key: Result key | |||
:return: Rendered template | |||
""" | |||
ds_start = time.time() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Likewise
webtool/views/views_dataset.py
Outdated
# TODO: Better way to identify this edge case? | ||
elif child.type.startswith("image-downloader"): | ||
# Images were downloaded from this zip; this is the case for presets | ||
for grandkid in child.get_children(instaniate_datasets=True): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TypeError: get_children() got an unexpected keyword argument 'instaniate_datasets'
Also, it would be nice to make this compatible with all image-generating/downloading processors, including 'Extract video frames'. |
cartographer does not understand the folder structure
Right now, I need the cartographer to understand what to do with subfolders of image groupings. Or perhaps Regardless, I think we could do better than to just splash the images semi in order. They could be automatically categorized by the subfolders they are in for example (mimicking the scene timeline). |
.metadata.json with directories currently expects filename only (not subdirs), but this could be changed.
Sorted out subfolder handling in cartographer. Works with the video-frames processor. Currently there is no usable .metadata.json file (looks to be copied over from higher level processor and does not have image filename references for post_ids to be extracted) so images have no descriptions. I did not do anything to categorize the images by scene. That's more complex as the categories are currently decided from the metadata (which does not exist). This would be a special case. |
…Processor.display_in_ui() Allow using `display_in_ui` to hide processors from UI but allow them to be queued either via API or presets. This avoids issue of is_compatible_with() having to be used to hide processors with sometimes ill effects.
…is_compatible_with
cannot just check plot since preview also checks child datasets of zips for plots
finally figured this out!
I would also suggest to rename the processor to something more specific. "Create Image visualisation" is a bit general; something like "Display images on Web page" is already a bit more concrete. Relatedly, it is a bit unclear to me what can I do with the outputted zip file. Can the description be updated so users are told what they can do with it? And maybe add a readme file in the zip results? As I understand it, the page opened by the "View" button is what's most interesting here right? Can't the zip file contain this page as well? Otherwise good work!! |
This is merge-able!
Notes:
@app.route('/result/<path:query_file>')
now can also load archived files.This may not be the best design and we might perhaps not archive the images since they have this new use. Recommend reviewing this part.Updated to open files and generate response on the fly.To-do:
I have done some basic editing to the PixPlot template, but it could benefit from more work.More editing done for 4CAT specific plots!Add metadata to the Image descriptionsMove the image description panel to one of the sides; it works where it is with the image filename only, but is not great/intuitive with further descriptionsedit add presets for tiktok and telegram image downloaders