load('WM811K.mat');
%% Select training and test data
trainTestLabel={data.trainTestLabel};
trainIdx=find(strcmp(trainTestLabel,'Training'));
%% Show each failure type
type={data.failureType};
disp(type);
trainFailureType=type(trainIdx);
%testFailureType=failureType(testIdx);
%waferFailType=unique(trainFailureType);
%% Plot a wafer map
idx=find(strcmp(trainFailureType,type{6}));
disp(type{6});
disp(length(idx));
for i=1:length(idx)
exampleIdx=trainIdx(idx(i));
waferMap=data(exampleIdx).waferMap;
%imagesc(waferMap);
myMap= [ 1 1 1; ... % empty elements use white color
0 1 1 ; ... % good dice use cyan color
1 0 1 ]; % defective dice use magenta color
%colormap(myMap);
filename = sprintf('Near Full_%d.jpg', i) ;
imwrite(waferMap,myMap,filename,'bmp');
end
0 comments:
Post a Comment