简体   繁体   中英

Neo4J relationship types

Neoclipse allows a relationship to follow an INCOMING or OUTGOING direction. I get this.

However, Neoclipse also allows a relationship to follow NO direction or BOTH directions.

A directionless relationship makes no sense to me. Why does Neoclipse offer this option?

I understand the need for bidirectional (ie, symmetric) relationships. Does anyone know of an example?

The reason for offering graph connections without an explicit direction is very useful for a great number of applications. The thing to realize is that with many graphs, the concept of a direction simply doesn't make sense. For instance, if I wanted to use neo4j to make a geographic model of a region to allow for super fast query between nearby locations, the importance is that two locations are linked, and the presence of any direction between them wouldn't really make any sense and would honestly probably make my code a lot less readable.

In a machine learning context, this could be used for something like a convolutional neural net, where again, certain nodes do not lead to other nodes, and if you for instance wanted to use this model in conjunction with another one, it might in fact make a lot of sense for you to use all four of these relationships together in the same graph.

As far as bi-directional relationships go, again my example will be from Machine Learning since that's my primary background, but in a Restricted Boltzmann Machine you generally have a top layer that is unidirectional and a bottom layer that is unidirectional with a number of layers between that are bi-directional. The idea behind this is that your results should directly imply the data that you put in to get them and vice versa.

For example: In a restricted Boltzmann Machine you could be trying to map a facial feature vector down to a specific emotion. The concept is that not only should your model be able to predict and emotion given a face, but it should also be able to predict a face given and emotion. By testing out a model in this way you can get results significantly better than straight NNs for many applications.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM