K4kArot2015 / sigplus

Automatically exported from code.google.com/p/sigplus
0 stars 0 forks source link

Filtering images based on keywords #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Wildcard sigplus paternss and this is a jet!

1. Module sigplus I embed for example in the article.
It would be great if I could write a filter that displays only those photos 
that currently need.

2. Sigplus ptrafi index name pictures in the gallery.
Another idea to filter the images in the gallery is to add menu selectbox with 
the key words retrieved from the file names.
Key words can be built from names such as images in the file name with an 
underscore "_"

file name:
owl_small_asian_Jon_large_portrait.jpg

Or according to the metadata.

Best regards!

Original issue reported on code.google.com by ten.mari...@gmail.com on 28 Apr 2012 at 8:36

GoogleCodeExporter commented 9 years ago
I am afraid this feature request is not defined clearly enough to permit a 
robust and effective implementation. It is not obvious how sigplus should be 
able to identify file names that use the keyword scheme (e.g. 
"owl_small_asian_Jon_large_portrait.jpg") from file names that do not (e.g. 
"new_york_city.jpg"), there is too much freedom in conventional file naming to 
make this possible. Using image metadata or additional information derived from 
another source (e.g. "labels.txt") seems a better approach but the exact syntax 
needs to be specified to make an implementation feasible.

In general, adding gallery management features to sigplus requires thoughtful 
consideration. The simplicity of sigplus lies in its straightforward concept of 
image source that is typically a regular folder in a file system. This saves 
the user from creating galleries via some management interface, and adding 
images to the galleries manually or semi-automatically. This, however, comes at 
a price, management features being more difficult to grasp effectively. Also, 
care must be exercised not to perform actions on behalf of the user (e.g. 
extract keywords) the user does not really want.

Original comment by huny...@gmail.com on 12 May 2012 at 12:20

GoogleCodeExporter commented 9 years ago

Original comment by huny...@gmail.com on 12 May 2012 at 12:21

GoogleCodeExporter commented 9 years ago
Do not know if I explained it well.
I mean instantly build a gallery solely based on keywords in the filename. 
Then, they can be extended but a quick sort can be obtained already in the file 
names.

I'm interested in this opportunity:

file name: "owl_small_asian_Jon_large_portrait.jpg"

{gallery}animals/owl_* , *_jon_* , *_portrait_*

Result is a gallery of photos by John only portrait only owls. 
This allows me to quickly build a gallery to continue that in the editorial 
work or for the moment.
Now, to get a similar effect in the work I need to not only edit the name of an 
image, label.txt and EXIF data. In practice, this pressure vices at this level 
needs.

There are even situations in which the images change so quickly on the server 
that probably not will never have its long name, keyword, except for a brief 
working name of the file.

Original comment by ten.mari...@gmail.com on 14 May 2012 at 8:38

GoogleCodeExporter commented 9 years ago
As far as I understand, the feature request comes down to being able to specify 
multiple patterns in the image source specification, a request that had been 
brought up earlier. This sounds as a legitimate request but it needs further 
consideration for proper syntax and design.

Meanwhile, I suggest relying on sigplus' ability to display images from 
multiple folders (i.e. a folder hierarchy) and the parameter "depth" with a 
positive value.

Original comment by huny...@gmail.com on 14 May 2012 at 11:17

GoogleCodeExporter commented 9 years ago
Yes you are right, in total about the same point. The possibility of reducing 
the filter files by more than one Wildcard pattern gives a great and flexible.

Original comment by ten.mari...@gmail.com on 14 May 2012 at 11:21

GoogleCodeExporter commented 9 years ago
multiple patterns in the image source specification — just to reduce the 
number of retrieved images. I wait with hope.

Original comment by venapr...@gmail.com on 18 May 2012 at 3:59

GoogleCodeExporter commented 9 years ago
Feature added in sigplus version 1.5.0.156.

Multiple patterns for selecting a group of files can be specified with the 
parameters "filter-include" (files to be included in the gallery) and 
"filter-exclude" (files not to be included in the gallery). The exclude filter 
is applied after the include filter, and the exclude filter takes precedence. 
Selector items are separated by semicolons and the semantics of the combination 
of items is an "or"-relationship.

[Example] Include files whose file name starts with "owl_", or includes the 
text "_jon_" or "_portrait_" but is not a PNG file:

{gallery filter-include="owl_*;*_jon_*;*_portrait_*" 
filter-exclude="*.png"}animals{/gallery}

Original comment by huny...@gmail.com on 23 Jun 2012 at 12:00

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
"Cut Samurai," as they say :) colleagues from Asia.
A great solution. A whole new ocean of possibilities.

Congratulations!
Will appreciate this fellow photographers but photo gency thesis and the whole 
world.

Original comment by ten.mari...@gmail.com on 23 Jun 2012 at 8:44

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
I have written a short wiki page on the topic under the wiki title 
"ImageFilters", essentially copying the relevant part of the discussion to a 
page of its own.

Original comment by huny...@gmail.com on 1 Aug 2012 at 3:23

GoogleCodeExporter commented 9 years ago
Does this parameter work for sure in the last version?

Original comment by ten.mari...@gmail.com on 1 Aug 2012 at 3:28

GoogleCodeExporter commented 9 years ago
Is this parameter is tested on a path / like /  birds  owl / 
What is to be entered into a subdirectory to the path parameter work?
Regards!

Original comment by ten.mari...@gmail.com on 2 Aug 2012 at 7:03

GoogleCodeExporter commented 9 years ago
Include and exclude filters, as the wiki documentation explains, operate on 
image file names. At the database level, image folders are listed in one table 
("#__sigplus_folder") and images are listed in another ("#__sigplus_image"), 
and the tables are joined by the image folder identifier ("folderid"). Filter 
expressions are matched against the column "filename" in the image table, which 
stores the image file name without a path.

Original comment by huny...@gmail.com on 2 Aug 2012 at 8:19

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hi!
I'm sorry again and write properly.
For some reason I can not set up or operate the "include". (my test page to 
which you have access)

I do not understand why the code shown in the attachments include filter 
displays all the image files that have the word "city" and "Budapest" in the 
name?

It should show only the files that contain the name of all the appropriate 
words.

I am wrong?

Original comment by ten.mari...@gmail.com on 30 Sep 2012 at 11:44

Attachments:

GoogleCodeExporter commented 9 years ago
I am afraid you are wrong, at least when compared to the documentation, which 
says "Selector items are separated by semicolons (;) and the semantics of the 
combination of items is an 'or'-relationship". For details, see:

http://code.google.com/p/sigplus/wiki/ImageFilters

In your case, the attribute name/value pair

filter-include="city*;*budapest*"

means to include all images that start with "city" OR contain the phrase 
"budapest".

Original comment by huny...@gmail.com on 30 Sep 2012 at 1:28

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Not, I am afraid. The comma (,) is not a supported join character. The 
semicolon (;), on the other hand, is a typical separator in many operating 
systems that may not occur in a legitimate file name, which is why it was 
chosen. Regardless of the separator, however, the phrases are always in an 
OR-relationship (city* OR *budapest*), and an AND-relationship (city* AND 
*budapest*) where both conditions are met, cannot be formulated. This is a 
limitation in the filter design, which you must live with at the moment.

Original comment by huny...@gmail.com on 1 Oct 2012 at 8:22

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
So, if I want to display a gallery of images that contain the name of all 
stored words, my code should look like this?

{gallery filter-include="city* AND *budapest*" preview_height=80 
alignment="center"}sigplus/sample{/gallery}

Original comment by ten.mari...@gmail.com on 1 Oct 2012 at 8:54

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Today, sigplus supports no such syntax. This might be a possible extension for 
the future.

Original comment by huny...@gmail.com on 1 Oct 2012 at 10:43

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Thank you for your patience with me :).
OK. I understand now use "include" refers to the gallery is not the way I 
wanted the file name.
It is also a good feature. Allows you to quickly build a gallery of images that 
contain the name of only certain words.

But I have a problem only to create a gallery of photographs that have all the 
specific words, not only one of the saved.

Unfortunately I can not create a name in which words are needed in the right 
formation, one after the other.

But in that case, I try to limit the effects of filters include and exclude 
files indicated at the end of the path?

{gallery filter-include="*budapest*" filter-exclude=*night* preview_height=80 
alignment="center"}sigplus/sample/*city*{/gallery}

Original comment by ten.mari...@gmail.com on 1 Oct 2012 at 11:23

GoogleCodeExporter commented 9 years ago
Technically, the code would allow compound expressions like

("*budapest*" AND "city*") OR (NOT "*drawing*")

but an implicit restriction stems from the context in which such an expression 
would be used, namely, the compound expression has to fit a parameter value in 
a name/value pair. Were the parameter value so complex as shown above, it would 
make it much more difficult to use. A compromise has been to use the semicolon 
(;) as a separator between items, which are interpreted in an OR relationship. 
This covers a wide range of use cases without severely limiting its expressive 
power. It is a pity that the expressive power you would need is beyond the 
expressive power currently supported.

Nonetheless, I am open to proposals how to extend expressive power provided 
that the resulting syntax is unambiguous and simple. This is more difficult to 
accomplish than it sounds but and ill-defined syntax can do more harm than 
good, and I must reduce support requests arising from possible errors at all 
costs, given how little free time I have already. :)

Original comment by huny...@gmail.com on 1 Oct 2012 at 3:30

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
I would like to accomplish this task:

1. find the specified directory all files whose names contain the phrase "* 
city_ *" and "* _night_ *" and "* _budapest_ *"
2. remove from the list of files that have the phrase in the name of "* _bath_ 
*" or "* _folks_ *"

3. Create a gallery. 

{gallery name-include="*city_*" AND "*_night_*" AND "*_budapest_*" 
name-exclude="*_bath_*" OR "*_folks_*"  preview_height=80 
alignment="center"}sigplus/sample/{/gallery}

Original comment by ten.mari...@gmail.com on 1 Oct 2012 at 3:59

GoogleCodeExporter commented 9 years ago
In this case, the rapid establishment of the gallery is not possible.

{gallery filter-exclude="*landscape*"}city/*Spain*{/gallery}

Original comment by ten.mari...@gmail.com on 10 Oct 2012 at 12:00