|
|
l****a 发帖数: 50 | 3 use matlab
help imread
IMREAD Read image from graphics file.
A = IMREAD(FILENAME,FMT) reads the image in FILENAME into
A. If the file contains a grayscale intensity image, A is
a two-dimensional array. If the file contains a truecolor
(RGB) image, A is a three-dimensional (M-by-N-by-3) array.
FILENAME is a string that specifies the name of the
graphics file, and FMT is a string that specifies the
format of the file. The file must be in the current
directory or i |
|
b********r 发帖数: 295 | 4 such as function: 'imread'
the input is the file name, the output the the pixel inforamtion matrix.
for example:
I=imread('C:\mypics\image_1.png'); |
|
|
s*****c 发帖数: 753 | 6 You can use imread in matlab. If the tiff is compressed
format, you can first convert it to other format supported
by imread, like bmp. |
|
k*****r 发帖数: 21039 | 7 [img, map]=imread("test.bmp");
figure(1);imagesc(img);colormap(map);axis image; axis off;
print('-depsc2', "test.eps");
close(1); |
|
p*******o 发帖数: 6791 | 8
当年看 A 片, 都是截成单桢的 imread 到 matlab 里, 做完 ifft, 然后再拼到一起看
...不过没有虚数部分效果不咋样... 他们加
码的时候做完 fft 用 abs 取实数部分了 |
|
|
x5 发帖数: 27871 | 10 imread,读进来是数组,随便怎么弄
完事再imwrite就可以了 |
|
s*****g 发帖数: 5159 | 11 matlab can do that without much coding.
img = imread('your file name');
xls_write(img, 'your excel file name'); (can be xls_print or other function,
please check).
matlabl is not cheap, and you need image processing tool box. |
|
M***e 发帖数: 133 | 12
function,
imread is not in the image processing toolbox. |
|
l********a 发帖数: 1154 | 13 OpenCV2.1之后,跟C++配合使用的时候
Mat,CvMat,IplImage,CvArr彻底把我搞混了
因为我读取图像的时候,
cvLoadImage是IplImage格式,imread是Mat格式;
存取矩阵元素时候,
cvG(S)et2D需要CvArr格式,cvmG(S)et又要CvMat
到底搞这么多格式干嘛?或者有没有什么通用的办法
让我存取矩阵的元素使用行和列就可以做到,好像matlab的a(i,j)一样方便?
请了解的高手指教一下.不吝感激. |
|
|
W*******o 发帖数: 301 | 15 self ding!
nobody knows? |
|
|
|
t****t 发帖数: 6806 | 18 没见他有什么特别要求啊,
不就是imread后面跟xlswrite吗
要揽活儿不是这么弄的... |
|
k**********g 发帖数: 989 | 19 Depends on how big the area is.
More precisely, what is the maximum distance from the set of missing pixels
to the nearest valid pixel.
The general technique is called Infilling.
Here's just an example from Google search result. http://research.microsoft.com/pubs/67276/criminisi_tip2004.pdf
When the text is very thin, a masked local averaging will do the job.
img = imread( filename ) ;
[ nrows, ncols, nchan ] = size ( img ) ;
imgColor = double ( img ) .* (1 / 255) ;
imgGray = rgb2gray ( imgColor... 阅读全帖 |
|
w***g 发帖数: 5958 | 20 终于打通了任督二脉,集成了所有的CNN库。
https://github.com/aaalgo/xnn.git
#include
cv::Mat image = cv::imread("xxx");
C++下用CNN预测简化为下面三行代码。
unique_ptr model(xnn::Model::create(model_dir, 1));
vector ft;
model->apply(image, &ft);
如果是分类问题, ft的长度就是类型个数。如果是
segmentation,ft就是输出图像的大小。
根据model_dir下的内容自动检测是caffe, mxnet还
是python (theano, tensorflow以及别的各种python库,
只要输入输出是numpy.array就行)。python库载入的时候慢点,
但是如果用batch mode跑,基本上没有overhead。
当然训练模型还是需要各显神通了。(很多模型可以直接从网上
下载。) |
|
b*****k 发帖数: 20 | 21 imread, then save as fig file. |
|
i********y 发帖数: 346 | 22 I tried imread and save but they did not work... anyway thanks. |
|
b*****k 发帖数: 20 | 23 are you kidding me?
imread -> imshow -> save as .fig file |
|
PK 发帖数: 1153 | 24 我有24张512*512的16位Intensity Image
用imread把每张图读进matlab,然后把每张剪裁一下,拼成一个620*930的图Ione
让后我想用imwrite把Ione存出来,可是却总有下面的错误
imwrite(Ione,'ww.tif','tif');
??? Error using ==> imagesci\private\writetif
Couldn't open 'ww.tif' for writing.
Error in ==> imwrite at 384
feval(fmt_s.write, data, map, filename, paramPairs{:});
而且奇怪的是当我用同样的方法去处理另外一组20张512*512的16位Intensity Image时
却没有任何问题
唯一区别在于这组的Ione只有348*435。
对matlab图像处理不太熟悉,希望大虾指点 |
|
d*******2 发帖数: 340 | 25 一个255灰度的黑白bmp文件,用
a=imread('file.bmp');
subplot(2,2,1)
imagesc(a)
print -deps2 file.eps
为什么产生的eps文件和bmp文件看起来大不一样? 哪位前辈知道?先谢了! |
|
c**o 发帖数: 38 | 26 imread----subplot----imshow????? |
|
|
l*******G 发帖数: 1191 | 28 Assume it is y=f(x) curve.
in matlab,
help imread
will tell you how to read a image
help imshow
will tell you how to show the image on your screen
help hold
will tell you how to plot one figure on top of another
help plot
you can use it to plot a frame that just covers the image with
or you can plot 4 dots that overlap with the 4 corners of the image
appropriate
x and y axises
help ginput
will tell you how to read position from the figure |
|
G*****D 发帖数: 490 | 29 MATLAB, a few seconds...
简单来说:
读入image使用imgmatrix=imread('c:\temp\abc.tif')
这样imgmatrix就是一个多维矩阵。想要其中一个点[x,y]的所有layer就使用imgmatrix
(x,y,:);想要很多点可以写个循环...
其实ERDAS imagine也可以。我记得在最上面的某个菜单里面有个output to ascii可以
用,有几个输入选项。 |
|
f*******r 发帖数: 204 | 30 For yourpurpose, it is simpler to find some software to digitize a curve
(by hand :)). I currrently use Grapher for digitizing. If you don't hav
e this software, try searching digitize in google to see whether there's
some free ware.
If using matlab, you can use "imread" to read the image into a matrix an
d write a program to find the profile by detecting the color change in t
he image. If the plot only have a single curve, it is better to scan the
plot into Black/White form; and then you will s |
|
t**t 发帖数: 9 | 31 如果是大批量的话,matlab的图像包就很合适.
核心程序就一行:
imwrite(imread(sFileName, srcfmt), strrep(sFileName, srcfmt, dstfmt), dstfmt);
支持很多格式. |
|
l**k 发帖数: 419 | 32
sigh, nobody replys. Here is the answer, for those who may interest.
[pic cmap] = imread (..);
fft_pic = fft2(pic);
power_pic = abs(fft_pic);
phase_pic = angle(fft_pic); |
|