Skip to content
This repository has been archived by the owner. It is now read-only.

fixed classification prediction for multiple nodules #273

Merged
merged 1 commit into from Jan 5, 2018

Conversation

@Serhiy-Shekhovtsov
Copy link
Contributor

@Serhiy-Shekhovtsov Serhiy-Shekhovtsov commented Jan 5, 2018

Bug fixed. When the length of the nodules list is more then 1 – prediction fails as follows:

~/concept-to-clinic/prediction/src/algorithms/classify/src/gtr123_model.py in predict(ct_path, nodule_list, model_path)
    275     results = []
    276 
--> 277     for nodule, (cropped_image, coords) in zip(nodule_list, patches):
    278         cropped_image = Variable(torch.from_numpy(cropped_image[np.newaxis, np.newaxis]).float())
    279         cropped_image.volatile = True

ValueError: too many values to unpack (expected 2)

More details here.

CLA

  • I have signed the CLA; if other committers are in the commit history, they have signed the CLA as well
Bug fixed. When the length of the nodules list is more then 1 – prediction fails as follows:

```
~/concept-to-clinic/prediction/src/algorithms/classify/src/gtr123_model.py in predict(ct_path, nodule_list, model_path)
    275     results = []
    276 
--> 277     for nodule, (cropped_image, coords) in zip(nodule_list, patches):
    278         cropped_image = Variable(torch.from_numpy(cropped_image[np.newaxis, np.newaxis]).float())
    279         cropped_image.volatile = True

ValueError: too many values to unpack (expected 2)
```

More details [here](#272 (comment)).

## CLA
- [x] I have signed the CLA; if other committers are in the commit history, they have signed the CLA as well
@reubano
Copy link
Contributor

@reubano reubano commented Jan 5, 2018

Thanks for this! Would you also mind adding a test that fails unless this patch is applied? That will make sure we don't create regressions with future changes.

@Serhiy-Shekhovtsov
Copy link
Contributor Author

@Serhiy-Shekhovtsov Serhiy-Shekhovtsov commented Jan 5, 2018

@reubano, sure. I will make a new PR for this.

@reubano reubano merged commit 3ff11bc into drivendataorg:master Jan 5, 2018
2 checks passed
2 checks passed
@drivendata
concept-to-clinic/cla @Serhiy-Shekhovtsov has signed the CLA.
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@Serhiy-Shekhovtsov Serhiy-Shekhovtsov mentioned this pull request Jan 10, 2018
1 of 1 task complete
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants