Program doesn't always start.

2 ビュー (過去 30 日間)
Douglas Brenner
Douglas Brenner 2016 年 9 月 16 日
コメント済み: Stephen23 2016 年 9 月 17 日
My program doesn't always run. I access my license through a VPN. Could that have something to do it with? Here's the code.
clear
include
for i = 3:3%1:nimages;
aviin = [transformeddir,base_name,'_transformed_', int2str(i),'.avi'];
disp('Converting')
disp(aviin)
a = VideoReader(aviin)
n_frames = a.NumberOfFrames;
frame=read(a,1);
Sum=double(frame);
for j = 2:n_frames;
frame = double(read(a,j));
Sum = Sum + frame;
end
Mean = Sum / n_frames;
figure(1), imshow(uint8(Mean));
[Gmag, Gdir] = imgradient(Mean,'prewitt');
rgbmag = ind2rgb(uint8(3*Gmag), flipud(jet(256)));
rgbdir = ind2rgb(uint8(Gdir), hsv(256));
figure(2);
imshow(rgbmag);
figure(3);
imshow(rgbdir);
end
  1 件のコメント
Stephen23
Stephen23 2016 年 9 月 17 日
"My program doesn't always run"
So what does it do? Does MATLAB print an error message or a warning, crash, go into an endless loop, quit without warning, show an incorrect output, or does your computer explode into flames?
Each of these can have different causes, so when you actually tell us exactly what is happening then we can actually help you. Until then you make us guess what "doesn't always run" means: I will interpret it to mean that your computer is tired and wants to go on holiday. The solution is thus to give it a massage and book it a week in the Bahamas.

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeDates and Time についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by