keiserlab / plaquebox-paper Goto Github PK
View Code? Open in Web Editor NEWRepo for Tang et al, bioRxiv 454793 (2018)
License: MIT License
Repo for Tang et al, bioRxiv 454793 (2018)
License: MIT License
I have being able to run notebooks 1.1, 1.2 and 1.3 successfully, but i am having issues with 2.1, i wanted to know how the CSVs directory and the excel files within the CSVs directory were generated, since the error message i receive when i run notebook 2.1 says, no such file directory found for both "train" and "dev".
When running 2.1) CNN Models - Model Training and Development.ipynb
on my Ubuntu 18.04 machine, in the 12th cell, I get the following error:
FileNotFoundError: Caught FileNotFoundError in DataLoader worker process 0.
Original Traceback (most recent call last):
File "<ipython-input-5-8e25f5046706>", line 32, in __getitem__
img_as_img = Image.open(self.img_path + single_image_name)
File "/home/user/.local/lib/python3.7/site-packages/PIL/Image.py", line 2766, in open
fp = builtins.open(filename, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'data/seg/size_filtered/blobs/NA4757-02_AB/NA4757-02_AB_13_24_27.jpg'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/user/.local/lib/python3.7/site-packages/torch/utils/data/_utils/worker.py", line 178, in _worker_loop
data = fetcher.fetch(index)
File "/home/user/.local/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/user/.local/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 44, in <listcomp>
data = [self.dataset[idx] for idx in possibly_batched_index]
File "<ipython-input-5-8e25f5046706>", line 34, in __getitem__
img_as_img = Image.open(NEGATIVE_DIR + single_image_name)
File "/home/user/.local/lib/python3.7/site-packages/PIL/Image.py", line 2766, in open
fp = builtins.open(filename, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'data/seg/negatives/NA4757-02_AB/NA4757-02_AB_13_24_27.jpg'
This is most likely due to a faulty train.csv
file or missing images in the data/seg/size_filtered/blobs/
directory. Reviewing the code, the error above is a result of the code attempting to load an image that does not exist:
def __getitem__(self, index):
# Get label(class) of the image based on the cropped pandas column
single_image_label = self.labels[index]
raw_label = self.raw_labels[index]
# Get image name from the pandas df
single_image_name = str(self.data_info.loc[index,'imagename'])
# Open image
try:
img_as_img = Image.open(self.img_path + single_image_name)
except:
img_as_img = Image.open(NEGATIVE_DIR + single_image_name)
# Transform image to tensor
if self.transform is not None:
img_as_img = self.transform(img_as_img)
# Return image and the label
return (img_as_img, single_image_label, raw_label, single_image_name)
Although I am not sure of the exact cause of this problem. I am trying to reproduce your results with your code, any ideas?
I have a question regarding the CSV files in this repository and CSV files in the Tiles.zip file (Zenodo).
What is the significance of the numeric value for each of the classes (cored, diffuse, CAA, negative). They are not in one-hot encoding, and also do not sum to 1 over rows which would suggest a probability distribution. For example: the second row in the screenshot below has CAA=2, Negative = 0.1233, Flag=2, and Not sure=0.1233. It easy to take the argmax and assume that is the ground truth, but I would like to better understand what these numbers mean for each column. Another image has Diffuse=1.9404 and Not sure=1. What do these numbers represent? Also, what is the significance of the numeric value for the "flag" column, if any?
Hello,
I am attempting to reproduce your results but am seeing differences in the WSI CNN count results. Example WSI NA5001_2AB:
All packages I have matched, e.g. version 3.4.1 of libopencv/opencv/py-opencv, version 0.3.0 of torch, pyvips 2.1.2 with libvips 8.2.2. I should say that I am on a Windows 10 machine so this could very well be the problem, but just wanted to check first that I haven't missed something else.
When running notebook 2.2) I get the same AUC-PRC scores and so it seems the model is working correctly and giving the correct confidence.
I have also checked the stain normalization is working as intended by comparing 256x256 patches from the training data set provided in the Zenodo link to the equivalent cropped images produced when processing the WSIs with notebooks 1.1)-1.3). So I believe the WSIs are correctly stain normalized.
Would it be at all possible to see your prediction confidence heatmap for the example above so that I can inspect? I suspect this is where the differences lie that lead to the discrepancy.
Hi, I'm trying to use the alzhaimer dataset in a explicability metric study and I'd like to know if could you provide de bound boxes coordinate of the tiles images.
Thank you.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.