Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Py 2 to 3 encoding errors #410

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fix Py 2 to 3 encoding errors #410

wants to merge 2 commits into from

Conversation

vbhavank
Copy link
Collaborator

@vbhavank vbhavank commented Jul 7, 2020

This merges changes made to path encodings in Caffe descriptor generator and fixed error during file upload.

@vbhavank vbhavank requested a review from Purg July 7, 2020 17:54
@lgtm-com
Copy link

lgtm-com bot commented Jul 7, 2020

This pull request introduces 1 alert when merging 13060fb into 9697837 - view on LGTM.com

new alerts:

  • 1 for Unused import

@@ -181,11 +181,9 @@ def _setup_network(self):
# - ``caffe.TEST`` indicates phase of either TRAIN or TEST
self._log.debug("Initializing network")
self._log.debug("Loading Caffe network from network/model configs")
self.network = caffe.Net(self.network_prototxt.write_temp(),
self.network = caffe.Net(self.network_prototxt,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

self.network_prototxt here, as well as self.network_model below, should be DataElement instances at this stage. I believe Caffe 1 wanted filepaths here, thus the previous write_temp() calls. Is this not the case any more? I realize that the caffe 1 generator might be getting a little stale at this point.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It still seems to accept a string as input. I can change the documentation in Linehttps://github.com/Kitware/SMQTK/blob/654f69e0db89ce7b0a2fd13b27ef503ed4523e6b/python/smqtk/algorithms/descriptor_generator/caffe_descriptor.py#L58 to string and the setstate function to reflect the same. Please let me know if you think that sounds right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants