Hi Chris,
(and thanks Jerven for responding too). I agree with Jerven that this
may be a Java VM optimization. Have you tried running this through a
Java profiler to get the "real" numbers?
Holger
On 9/19/2013 18:38, Jerven Bolleman wrote:
Hi Chris,
Disclaimer: Not a SPIN developer or related to topquandrant.
On 19/09/13 09:46, Chris Baillie wrote:
I am using a SPIN reasoner to apply SPIN rules to data contained within
a JENA model.
For each run of SPINInferences, the code does:
- Gets the SPINModuleRegistry and inits it.
- Adds my JENA model and the model containing the SPIN rules to the
registry.
- Runs SPINInferences on the models and generates a set of
SPINStatistics.
- Resets the SPINModuleRegistry so that the next pass is completely
fresh.
In the first instance, I apply a set of four SPIN rules to 350 models,
and (on average) these take around 10 milliseconds to complete
(calculated using the SPINStatistics results). During this run, the
rules produce annotations in the ntriples model which are added back
into the original model for the second pass.
In the second pass, I apply the same set of SPIN rules to these 350
models including their annotations. The rules do not consider these new
annotations and so, at the very least, the average reasoning time (calc.
using SPINStatistics) should be roughly the same. However, due to the
larger model size it could be expected that the time will increase.
Unfortunately, the reasoning time is reduced during the second pass (on
average, roughly 7ms.
Why is unfortunate that things go faster over time? Of course do you
know if the 3ms difference is statistically stable? Program execution
time on modern multi-processor computers with running multi-threaded
or multiple processes is not deterministic.
I assume that this is possibly caused by some kind of optimisation
within SPIN.
The optimizations can be on lower levels e.g. the Java JIT optimized a
significant amount of code during the first run making the second run
faster. Cache effects etc...
> Do you agree? If so, is there any way to switch this off?
Is it caused by me resetting SPIN the wrong way? What is the correct way
to do this?
Thanks
Chris
Regards,
Jerven
--
-- You received this message because you are subscribed to the Google
Group "TopBraid Suite Users", the topics of which include Enterprise
Vocabulary Network (EVN), TopBraid Composer, TopBraid Live, TopBraid
Insight, SPARQLMotion, SPARQL Web Pages and SPIN.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/topbraid-users?hl=en
---
You received this message because you are subscribed to the Google
Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.
--
-- You received this message because you are subscribed to the Google
Group "TopBraid Suite Users", the topics of which include Enterprise Vocabulary
Network (EVN), TopBraid Composer, TopBraid Live, TopBraid Insight, SPARQLMotion, SPARQL
Web Pages and SPIN.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/topbraid-users?hl=en
---
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.