An Efficient Spatial Approximate Search with Service Oriented Application Ch.Sridhar, M.Rambabu

advertisement
International Journal of Engineering Trends and Technology (IJETT) – Volume 15 Number 6 – Sep 2014
An Efficient Spatial Approximate Search with
Service Oriented Application
1
Ch.Sridhar, 2M.Rambabu
1
Final year M.Tech Scholar, 2Associate professor
Dept of CSE, Kaushik College of Engineering & Technology. Gambheeram
1,2
Abstract: We are proposing an empirical model of mechanism for
spatial search with efficient service oriented technology, although
though different traditional approaches are proposed by various
researchers for retrieval of results, based on the spatial or location
based queries and u location based query or spatial object is an
integrated part of an object location and set of features or
attributes in location. In our proposed approach we are handling
the location based queries with service oriented application or
web services, to maintain the language interoperability and cache
implementation improves the performance
I. INTRODUCTION
Spatial databases maintain geographical or location
based information as points or rectangles. Locations like
restaurants, hotels, colleges are stored as points and lakes,
parks can be represented with rectangles and landscapes
can be represented in set of rectangles. In range search
query nearest data can be retrieved based on distance and
feature set.
In real time applications like weather reports
locations can be represented as points in map. In
conventional mechanism spatial query can be passed as
restaurant with set of features {“chicken”, “wine”, ”drinks”
},in this straight forward approach ,it initially filter all
restaurants and checks available features in the restaurant.
Second process is reverse process, retrieve all restaurants
based distance and available feature set but these traditional
process are complex while real time format of input
queries.
Spatial databases are different from relational
database to retrieve the data from database. In traditional
approaches R trees are implemented to search spatial
information, later it can be developed as IR tree.IR tree is
flexible to retrieve the spatial relations and avoids
unnecessary examines.
The IR2-tree is the first access method for answering NN
queries with keywords. As with many pioneering solutions,
the IR2-tree also has a few drawbacks that affect its
efficiency. The most serious one of all is that the number of
false hits can be really large when the object of the final
result is far away from the query point, or the result is
simply empty. In these cases, the query algorithm would
need to load the documents of many objects, incurring
expensive overhead as each loading necessitates a random
access. To explain the details, we need to first discuss some
ISSN: 2231-5381
properties of SC (the variant of signature file used in the
IR2-tree). Recall that, at first glance, SC has two
parameters: the length l of a signature, and the number m
of bits chosen to set to 1 in hashing a word. There is, in
fact, really just a single parameter l, because the optimal m
(which minimizes the probability of a false hit)
II. RELATED WORK
Standard search engine follows file relevance
score mechanism to rank the documents and it follows
index based structure called an inverted index to retrieve
keywords and pages which contains the keywords and
computes the frequency of the keywords. both term
frequency and inverse document frequency. ranking
function works based on these frequencies.
we design a variant of inverted index that is
optimized for multidimensional points, and is thus named
the spatial inverted index (SI-index). This access method
successfully incorporates point coordinates into a
conventional inverted index with small extra space, owing
to a delicate compact storage scheme. Meanwhile, an SIindex preserves the spatial locality of data points, and
comes with an R-tree built on every inverted list at little
space overhead. As a result, it offers two competing ways
for query processing. We can (sequentially) merge multiple
lists very much like merging traditional inverted lists by
ids. Alternatively, we can also leverage the R-trees to
browse the points of all relevant lists in ascending order of
their distances to the query point. As demonstrated by
experiments, the SI-index significantly outperforms the
IR2-tree in query efficiency, often by a factor of orders of
magnitude.
Even though various approaches released by
various authors over spatial query retrieval, prefix is
required for top k retrieval of spatial data. K nearest
neighbor generates inverted index with R tree which is
used to find nearest neighbors if attribute set contains in
spatial query. Spatial object is a combination of spatial
object and its feature set.
Let D be a dataset in which each object p ∈ D is a
pair (λ, ψ) of a spatial location p.λ and a textual description
p.ψ (e.g., the facilities and menu of a restaurant). Similarly,
a spatial keyword query [3] q = _λ, ψ_ has two
components, where q.λ is a spatial location and q.ψ is a set
of keywords. The answer to query q is a list of k objects
that are in ascending order of their distance to the query
http://www.ijettjournal.org
Page 313
International Journal of Engineering Trends and Technology (IJETT) – Volume 15 Number 6 – Sep 2014
location q.λ and whose descriptions contain the set of query
keywords q.ψ Formally, let the function dist( ・ , ・ )
denotes the Euclidean distance between its argument
locations, and let D(q.ψ) = {p ∈ D | q.ψ ⊆ p.ψ} be the
objects in D that contain all the keywords in q. The result
of the top-k spatial keyword query q, q(D), is a subset of
D(q.ψ) containing k objects such that ∀p ∈ q(D) (∀p_ ∈
D(q.ψ)−q(D) (dist(q.λ, p.λ) ≤ dist(q.λ, p_.λ))). The joint
top-k spatial keyword query Q is a set {qi} of such queries.
We introduce the following notion to capture useful
information on a joint query Q: (i) Q.λ = MBRqi∈Q qi.λ is
the minimum bounding rectangle (MBR) of the locations
of the sub queries in Q, (ii) Q.ψ = ∪qi∈Q qi.ψ is the union
of the keyword sets of the sub queries in Q, and (iii)
Q.m = minqi∈Q |qi.ψ| is the smallest keyword set size of a
sub query in Q. We later define a variable qi.τ that captures
the upper bound kth nearest neighbor distance of sub query
qi. The value Q.τ = maxqi∈Q qi.τ then represents the
maximum upper bound kth nearest neighbor distance of all
the sub queries in Q. 3Referring to Figure 1, the joint query
Q contains three sub queries q1, q2, and q3 (shown as
shaded dots). The objects (e.g., restaurants) are shown as
white dots. We have that: q1.ψ = {curry, sushi}, q2.ψ =
{seafood, sushi}, q3.ψ = {curry, seafood}. Note that Q.λ
denotes the MBR of the shaded dots in the figure. We also
have: Q.ψ = {curry, seafood, sushi} and Q.m = 2.
node and compare all features of the query node with all
node features until it meets the leaf node and add the
results to the list frequently and returns the result
Input : Input Query, Cache based Queries
Output: distance based Result set generated for input query
Procedure:
If input Query available in cache
Query_result: =
Forward_To_Treeprocess
(input Query)
Else
Query_result: = Geocoding_treeProcess (input
Query)
Geocoding process (Query)
Parameters
Qi—Input location based Query
Qj (k=1…n) ---Set of inputQueries contains same
Location
Dist[j] (k =1…..n) -----Array for set of Euclidean distances
Procedure:
(xi,yi)---Geo parameters of Qi
(xj,yj)--- Geo parameters of all retrieved queries with
respect to location
Dist[i] = Euclidean distance between the geo parameters
While (not leaf node)
Read nodes from tree For Q.attributeset
If Q. attribute set [i]==Q. attribute set [j]
Add to list
End while
Sort list by attribute and Euclidean distance
Return list.
ForwardToTreeprocess ()
Figure1: A Dataset of Spatial Keyword Objects
PROPOSED SYSTEM
In this work we have proposed an efficient and
novel approach for handling geographic or spatial query
based on geo parameters (latitude and longitudes) and to
increase performance and to reduce overhead on server, we
proposed Cache implementation. We implemented both
search mechanisms with cache and without cache. Our
entire process is divided in to two parts based on cache and
geo parameters.
Geo parameters process the input query and
object based geo parameters and finds geo parameters of
the respective user from where he made a query and get the
geocoding values from the all the queries from the tree and
computes distance with all the query nodes and input query
ISSN: 2231-5381
1. Build an empty list
2 .create a root node
3. if Qi in cache and status=false
For j=0 to n
Compare attributes (Qi,Qj) status=true;
For Each child in tree
If(status==true)
Getnode_by_feature (Qi);
Getnode_by_feature (Qj);
End
Else
Empty list ()
End For Each
4. Add nodes to list
5. Return list
http://www.ijettjournal.org
Page 314
International Journal of Engineering Trends and Technology (IJETT) – Volume 15 Number 6 – Sep 2014
Web service is one of technology to create SOA
(service oriented architecture) with three tier architecture, it
minimizes duplication of operations by maintain the
business logic at specific one location (centralized server).
The main goal of the service oriented architecture is
language interoperability (i.e. any standard language can
communicate with other language even though both are
different languages) and minimizes the damage chances
of malfunctioning program from the user end who are
working with user interface.
Database
Business Logic
Wsdl with Soap protocol
UI (VB.Net)
Data Cache is a mechanism which increases the
performance from user end and reduces over head from
server end and stores frequently access results for future
retrieval when user requested for same input query it
reduces execution time i.e (round trip over the input
request and response time from server during the user input
query can be minimized in terms of time complexity and
minimizes additional overhead on server to process the
same input keyword. If any user request with same input
query which is requested before, query
need not to
process by server again and no need of a round trip,
because previous search results retrieved from the web
server before forwarded to user and it can be stored in data
cache, next search onwards input query results retrieved
from cache storage instead of web server.
IV. CONCLUSION
we are concluding our research work with an efficient
and novel search mechanism on location based or
geographical based databases with simple cache
implementation instead of complex tree constructions like
R tree implementation, in both cache based and non-cache
based implementation (with geo-codings ),our proposed
approach shows an optimal results than traditional tree
implementation approaches.
ISSN: 2231-5381
UI (Android)
UI (Java)
REFERENCES
[1] Y.-Y. Chen, T. Suel, and A. Markowetz. Efficient query processing in
geographic web search engines. In SIGMOD, pp. 277– 288, 2006.
[2] G. Cong, C. S. Jensen, and D. Wu. Efficient retrieval of the top-k most
relevant spatial web objects. In VLDB, pp. 337–348, 2009.
[3] I. De Felipe, V. Hristidis, and N. Rishe. Keyword search on spatial
databases. In ICDE, pp. 656–665, 2008.
[4] M. Duckham and L. Kulik. A formal model of obfuscation and
negotiation for location privacy. In PERVASIVE, pp. 152–170, 2005.
[5] A. Guttman. R-trees: a dynamic index structure for spatial searching.
In SIGMOD, pp. 47–57, 1984.
[6] R. Hariharan, B. Hore, C. Li, and S. Mehrotra. Processing spatialkeyword (SK) queries in geographic information retrieval (GIR) systems.
In SSDBM, p. 16, 2007.
[7] T. Brinkhoff, H. Kriegel, and B. Seeger. Efficient processing of spatial
joins using R-trees. Proc. SIGMOD, pages 237–246, 1993.
[8] G. Cong, B. Ooi, K. Tan, and A. Tung. Go green: recycle and reuse
frequent patterns. In Data Engineering, 2004. Proceedings. 20th
International Conference on, pages 128–139.
[9] A. Corral, Y. Manolopoulos, Y. Theodoridis, and M. Vassilakopoulos.
Closest pair queries in spatial databases. Proc. SIGMOD, pages 189– 200,
2000.
[10] I. D. Felipe, V. Hristidis, and N. Rishe. Keyword search on spatial
databases. In Proc. ICDE International Conference on Data Engineering,
2008.
[11] A. Guttman. R-trees: A dynamic index structure for spatial searching.
Proc. SIGMOD, pages 47–57, 1984.
[12] R. Hariharan, B. Hore, C. Li, and S. Mehrotra. Processing spatial
keyword (sk) queries in geographic information retrieval (gir) systems. In
SSDBM, page 16, 2007.
[13] G. Hjaltason and H. Samet. Incremental distance join algorithms for
spatial databases. Proc. SIGMOD, pages 237–248, 1998.
[14] H. Jagadish, R. Ng, B. Ooi, and A. Tung. ItCompress: An Iterative
Semantic Compression Algorithm. In Proceedings of the 20th
International Conference on Data Engineering (ICDE04), volume 1063,
pages 20–00.
[15] H. V. Jagadish, N. Koudas, and D. Srivastava. On effective multidimensional indexing for strings. Proc. SIGMOD, pages 403–414, 2000.
http://www.ijettjournal.org
Page 315
Download