|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object Feature.FeatureInterface
public class FeatureInterface
Implements the interface for managing features.
Constructor Summary | |
---|---|
FeatureInterface(FeatureManager.FeatureManager fm,
java.lang.String tempPath)
Query-only constructor (no RawDataManager is used). |
|
FeatureInterface(RawDataManager rdm,
FeatureManager.FeatureManager fm,
java.lang.String tempPath)
Basic constructor. |
Method Summary | |
---|---|
Document.Image |
extractImage(javax.media.jai.PlanarImage image,
Document.ImageID id)
Given an image and its ID extracts its Windsurf features. |
Document.Image |
extractImage(java.lang.String url,
Document.ImageID id)
Given an image URL and its ID extracts its Windsurf features. |
boolean |
findID(Document.ImageID id)
Checks whether an image with a given ID is contained in the feature DB. |
double |
getDistance(Document.ImageID id1,
Document.ImageID id2)
Computes the distance between two images, given their IDs. |
FeatureManager.FeatureManager |
getFeatureManager()
Returns the FeatureManager in use. |
Document.ImageID |
getID(java.lang.String url)
Checks whether an image with a given URL is contained in the feature DB. |
java.lang.String |
getImageURL(Document.ImageID id)
Retrieves the URL of an image with a given ID. |
RawDataManager |
getRawDataManager()
Returns the RawDataManager in use. |
java.util.Vector<QueryProcessor.SF.ScoredResultImage> |
kNNQuery(Document.ImageID id,
int k,
QueryProcessor.SF.ScoringFunction.ScoringFunction sf)
Performs a k-NN query for a given image using a sequential scan. |
Document.Image |
retrieveImage(Document.ImageID id)
Given an image ID retrieves its features from the DB. |
Document.ImageID |
storeID(java.lang.String url)
Given an image URL retrieves its ID (if the image is in the DB) or stores it (and its features) in the DB. |
Document.ImageID |
storeID(java.lang.String url,
Document.ImageID id)
Given an image URL retrieves its ID (if the image is in the DB) or stores it (and its features) in the DB. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FeatureInterface(RawDataManager rdm, FeatureManager.FeatureManager fm, java.lang.String tempPath)
rdm
- The RawDataManager to be used.fm
- The FeatureManager to be used.tempPath
- Directory used for storing temporary index files.public FeatureInterface(FeatureManager.FeatureManager fm, java.lang.String tempPath)
fm
- The FeatureManager to be used.tempPath
- Directory used for storing temporary index files.Method Detail |
---|
public FeatureManager.FeatureManager getFeatureManager()
public RawDataManager getRawDataManager()
public Document.ImageID storeID(java.lang.String url, Document.ImageID id)
url
- URL of the image to be searched/stored.id
- ID of the image to be inserted (null
if this is given by the DB).
public Document.ImageID storeID(java.lang.String url)
url
- URL of the image to be searched/stored.
public Document.Image extractImage(java.lang.String url, Document.ImageID id)
url
- URL of the image to be processed.id
- ID of the image to be inserted.
public Document.Image extractImage(javax.media.jai.PlanarImage image, Document.ImageID id)
image
- JAI image to be processed.id
- ID of the image to be inserted.
null
if there is an error during feature extraction).public Document.Image retrieveImage(Document.ImageID id)
id
- ID of the image to be searched.
null
if such image is not found.public boolean findID(Document.ImageID id)
id
- ID of the image to be searched.
true
if an image with the given ID exists in the features DB, false
otherwise.public java.lang.String getImageURL(Document.ImageID id)
id
- ID of the image to be searched.
null
otherwise.public Document.ImageID getID(java.lang.String url)
url
- URL of the image to be searched.
public double getDistance(Document.ImageID id1, Document.ImageID id2)
id1
- ID of the first image.id2
- ID of the second image.
public java.util.Vector<QueryProcessor.SF.ScoredResultImage> kNNQuery(Document.ImageID id, int k, QueryProcessor.SF.ScoringFunction.ScoringFunction sf)
id
- ID of the query image.k
- Number of requested results.sf
- Scoring function to be used.
ScoredResultImage
s or null
if the query image does not exist.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |