Subject: Re: [geometry] [index] support for serialization and external memory?
From: Adam Wulkiewicz (adam.wulkiewicz_at_[hidden])
Date: 2013-07-11 12:04:29
Mateusz Loskot wrote:
> On 11 July 2013 15:58, feverzsj <feverzsj_at_[hidden]> wrote:
>> hi, list
>> Is it possible for the index to serialize its internal tree structure(and
>> user data), so that the index can be rebuilt without reinsert?
> There is no such mechanism provided. AFAIK, it's planned in future.
Currently you can't do it without using hidden internals. There are
plans to expose some mechanisms or provide new ones to allow users
handling arbitrary serialization routine, along with incremental and
automatic saving of modified nodes. But I don't know when they'll be
>> And furthermore, is it possible to support an external memory based index?
>> But, as far as I can see, the current index interface and concept do not
>> expose enough on the tree structure to achieve these purpose.
> Yes, you are right, it's not feasible, though I'd be interested to learn myself
> if it is.
The rtree supports stateful allocators. If you can write an
external_memory_allocator compatible with STD allocator interface it
should work out of the box. Then all data: nodes, containers storing
children (if dynamic version is used) and children (this includes
values) will be stored directly in this memory. However AFAIK it won't
be possible to load the tree this way.
Geometry list run by mateusz at loskot.net