Win a copy of Machine Learning with R: Expert techniques for predictive modeling this week in the Artificial Intelligence and Machine Learning forum!

Gary W. Lucas

Ranch Hand
+ Follow
since Jun 25, 2014
Cows and Likes
Cows
Total received
7
In last 30 days
0
Total given
0
Likes
Total received
10
Received in last 30 days
0
Total given
8
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Gary W. Lucas

First off, I'm really interested in seeing your book.  My own experience with graph theory is limited to the old-school stuff and I would very much like to learn more about how it relates to big data applications.

My question:  How do Apache Spark and Neo4j hold up in terms of performance and memory use compared to some of the non-Java/non-JVM API's?

I ask because in the past I've found that graph-related applications require a lot of objects (edges, nodes, etc.) and that the overhead for Java object construction and memory use gets to be a problem.  Seeing how successful Apache Spark is, it seems likely that they've addressed the issue. I am curious as to what your experience has been.

Best of luck on your book.

Gary

Stephan,

Thank you again for the insights your provided about Maven.  You helped clarify a number of issues that had confused me.

Gary
8 months ago
Thanks Tim!

Recognizing that the Tinfour project has a relatively narrow user base, I tried to provide enough information to make it accessible to those developers who would be interested in using it.

When you refer to "pretty" documentation,  I take it you saw the project wiki pages?  Since Triangulated Irregular Networks (TINs) are kind of a specialized topic, I felt it would help potential developers if I provided background information on some of the theory and applications. So I've started posting wiki pages.  Some of them are better than others, but my favorite would have to be the one on Robin Sibson's Natural Neighbor Interpolation algorithm.  I think that Natural Neighbors is one of the most under-appreciated interpolation techniques out there.  Sibson died just a couple of years ago, so I have no idea what he would have thought of my work.  But I think that anything I can do to make the Natural Neighbors technique more available to potential applications is effort well spent.  
8 months ago
Stephan,

Thanks for the assessment and for taking the time to put together a Pull Request.  I will look at it this weekend.    I spent a lot of time looking at the documentation, but I came away with the feeling that there are fundamental Maven use patterns  that I am just not seeing.  So your updated POMs are especially welcome.  

You caught one issue in particular that concerns me. The core module is not supposed to have dependencies on anything except the standard Java API.  I'll have to figure out how the commons-math3 dependency  got in there.

Gary
8 months ago
Thanks again to the forum members who provided answers and useful advice to my original post.  My open-source project has now completed the initial transition to a Maven build environment.   I've also posted compiled Jar files on the Maven Central Repository.

Anyone would look like to see how it turned out, may do so by looking at https://github.com/gwlucastrig/Tinfour

I've got to say that there was a lot of learning curve on this.  And I steadfastly hope nobody tries to use my project as an example when doing their own work...  

If anyone spots something that needs fixing or improvement, I welcome your suggestions.

Gary


8 months ago
Stephan,

Thanks again.   I will follow your advice add a comment to my pom.xml indicating the version of maven I use.


I've tried to keep my project organization simple and non-innovative as possible, so hopefully maven versions will never be a problem.

10 months ago
Stephan,

Thanks again for the suggestion.  I've picked up a couple of important nuances from your examples. For instance, I'm using macro's such as plugin.version through the tree.

A question.  Following an example in the Apache Maven "getting started" page, I used a maven artifact to automatically generate an example pom.  When I did, it included a substantial number of entries under "pluginManagement".  The generated pom,xml includes the comment "lock down plugins versions to avoid using Maven defaults".  But it adds a lot of ugly clutter to the pom and, having looked at a bunch of pom.xml files in various projects,  it seems to me that most developers leave that out.  I also see that you don't use it in your own "Evolution" pom.  Is it a good idea to include the plugin version specifications?  I'd prefer to leave it out because the extra specifications degrade the signal-to-noise ratio of the specification in terms of a human trying to understand the structure of the pom...  though if it's necessary as a coding practice, that would be more important than readability.
10 months ago
Well, I wish I'd seen this discussion back when your originally posted it.  I regret that I couldn't reply sooner.  

I encountered this problem in my own Delaunay Triangulation (triangle mesh) implementation, including the special case of a triangle with a fictitious vertex.

I think your best solution would be to simply implement your own contains method from scratch.   First off, none of the standard polygon classes are going to understand the idea of a fictitious vertex (for everyone else: triangles with fictitious vertices are often used in Delaunay Triangulations to handle the region outside the bounds of the triangle mesh).   Second off, because the triangle has special properties (it's always a convex polygon, it has a fixed number of sides), it's easy to code a custom contains() method.  For example,  simply test a point against each edge to see if it is on the left or right side of the edge.  If you know that the triangle is oriented counterclockwise, then an inside point must lie to the left of each edge (always left or always right, a mix means the point is exterior).  If the triangle is clockwise, the point must be to the right.  And if you don't know the orientation, just recall that the inside point must be on the same side of each edge.  In the case of your fictitious triangle test, you would perform the left/right-side test for the true edge and then try dropping the point down to the edge line to see if lies within the segment.  Of course, there are complicating factors in this because an exterior point could lie in the pie-shaped wedge between two exterior border segments.

If you look at the GeometricOperations class in the Tinfour Project you will find some code related to this computation.  In Tinfour, all the triangles are always oriented counterclockwise, so you would have to make adjustments for your own logic.
10 months ago
Stephan,

Thanks.  I'll take a look.

I figure that if I can find three or four different projects, they'll pretty much cover all the variations.

Gary
10 months ago
I am looking for a few good examples of Java projects using Maven on github. Does anyone have recommendations?

I have a github-resident project that provides a library for building triangulated meshes (Delaunay Triangulations), analyzing airborne Lidar, and performing a few other computational-geometry functions (see  The Tinfour Project).  I think I did an okay job on the algorithm and coding aspects of the project, but I made some mistakes in terms of project organization and build utilities when I first set it up.

Anyway, I am currently working on refactoring the project to use Maven and eventually hope to post my libraries to a public repository. I've spent a good deal of time looking at documentation and thinking about the best way to organize things.  Every so often, I stumble across some aspect of the project that seems a bit fuzzy.   So I am hoping to find examples of projects that have proper treatments for organization and build issues.

For instance, right now I'm trying to figure out the best way to set up my Javadoc (into which I've put a lot of time).  I've been looking through the web, but the discussions I've found don't seem to relate well to working with github. Seeing a example of somebody who correctly implements the Maven conventions would really help.

In general, I'd like to see a project or two that
  • Isn't too big
  • Has good Javadoc
  • Builds multiple Jar files (multiple modules)
  • Doesn't do anything too customized (sticks to standard approaches)
  • Has a small but non-zero number of external dependencies


  • Thanks in advance for your help,

    Gary
    10 months ago
    Thanks.  I've been looking forward to playing with value types for a long time.  
    11 months ago

    I have a question for Mr. Verhas:

    Mainly out of self-preservation, I always try to wait 6 months or so before moving to the latest major release of Java.  And the organization I work for is even more careful with that regard.  So we're a bit worried about Java 11 and Oracle's announced new release strategy.  From my (admittedly cursory reading), it looks like Java will be undergoing major releases much more often than it formerly did.

    I was  wondering whether your book offers any strategies for coping with the potential for Java going through rapid versioning schedules.   Does the module system provide techniques for dealing with that kind of thing?

    Gary
    11 months ago
    Noah,

    Thanks. I like your metaphor.  In this case, it strikes me as being excellent advice.


    Gary

    Noah,

    I am just starting with a cloud-related project and am thinking that there are at least some aspects of what we're doing that might be tackled using AI-based tools. Do you have any tips on what to look for when sussing out a problem to see if AI is a suitable approach?

    Gary

    Noah,

    You had me at "pragmatic".

    Welcome to the forum.  I've just taken a look at the table of contents for your book and I've got to say you've got a really interesting combination of topics. Some problems are best approached from multiple directions, and I think that AI may be one of those.  I'm looking forward to reading your book.

    Gary