[GitHub] anjishnu commented on issue #8625: Attempting to write a relation network in Gluon

2017-11-18 Thread GitBox
anjishnu commented on issue #8625: Attempting to write a relation network in 
Gluon
URL: 
https://github.com/apache/incubator-mxnet/issues/8625#issuecomment-345434219
 
 
   Relevant thread : 
https://discuss.mxnet.io/t/cross-product-style-architectures-with-gluon/271/3
   
   The model doesn't throw an exception on the latest mainline branch built 
from source, but I haven't gotten the network produce anything other than the 
same prediction for every sample. 
   
   And it throws an exception if I try to apply batch-normalization to 
stabilize training.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] anjishnu commented on issue #8625: Attempting to write a relation network in Gluon

2017-11-18 Thread GitBox
anjishnu commented on issue #8625: Attempting to write a relation network in 
Gluon
URL: 
https://github.com/apache/incubator-mxnet/issues/8625#issuecomment-345434219
 
 
   Relevant thread : 
https://discuss.mxnet.io/t/cross-product-style-architectures-with-gluon/271/3
   
   The model doesn't throw an exception on the latest mainline branch built 
from source, but I haven't gotten the network to train yet. And it throws an 
exception if I try to apply batch-normalization. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] anjishnu commented on issue #8625: Attempting to write a relation network in Gluon

2017-11-14 Thread GitBox
anjishnu commented on issue #8625: Attempting to write a relation network in 
Gluon
URL: 
https://github.com/apache/incubator-mxnet/issues/8625#issuecomment-343760917
 
 
   I guess I essentially need to do the equivalent of the code below, but with 
the all_relations array being a memory view rather than a copy... 
   
   ```python
   num_relations = num_objects * num_objects
   #all_relations = []
   all_relations = mx.nd.zeros((batch_size * num_relations, hidden_dim 
* 2))
   for i in range(num_objects):
   first_object = z1[:, i, :]
   for j in range(num_objects):
   second_object = z2[:, j, :]
   relation_vector = mx.nd.concat(first_object, second_object, 
dim=1)
   start_index = ((i * num_objects) + j) * batch_size
   #all_relations.append(relation_vector)
   all_relations[start_index : start_index + batch_size] = 
relation_vector
   
   ```


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] anjishnu commented on issue #8625: Attempting to write a relation network in Gluon

2017-11-12 Thread GitBox
anjishnu commented on issue #8625: Attempting to write a relation network in 
Gluon
URL: 
https://github.com/apache/incubator-mxnet/issues/8625#issuecomment-343760917
 
 
   I guess I essentially need to do the equivalent of the code below, but with 
the all_relations array being a memory view rather than a copy... 
   
   ```python
   num_relations = num_objects * num_objects
   #all_relations = []
   all_relations = mx.nd.zeros((batch_size * num_relations, hidden_dim 
* 2))
   for i in range(num_objects):
   first_object = z1[:, i, :]
   for j in range(num_objects):
   second_object = z2[:, j, :]
   relation_vector = mx.nd.concat(first_object, second_object, 
dim=1)
   start_index = ((i * num_objects) + j) * batch_size
   #all_relations.append(relation_vector)
   all_relations[start_index : start_index + batch_size] = 
relation_vector
   
   ```


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services