对sav传参数呢?注意下面两个问题即可 1.代码pro文件中的参数接收 仍然是那个COMMAND_LINE_ARGS函数 Pro TestIDLArgs compile_opt idl2 Result = Command_Line_Args(Count=c) r = Dialog_Message('There are ' + Strtrim(c,2) + ' input args.', /info) if c gt 0 then begin for i=0, c-1 do begin help, Result , output=out r = Dialog_Message('arg' + Strtrim(i+1, 2) + ': ' + out , /info) endfor endif End 2.sav调用时参数传入 两种调用,直接调用sav,另外是工程发布后调用exe。 1) 开始 菜单运行,直接输入 C:\Program Files\ITT\IDL71\bin\bin.x86\idlrt.exe d:\testIDLargs.sav -args abcdef 2)工程用make_rt发布后,其实配套给你一个工程同名的exe来调用sav,类似的参数就需要修改testidlargs.ini文件,如传递ab'的话ini文件可修改为
功能是计算线段与坐标轴的夹角,与中学时学的一样,计算线段AB返回结果是那个,单位为弧度。 ;根据两点坐标返回线段与坐标轴的夹角(弧度) ;Point1到point2线段(线段AB) ; Function Cal2PointsAngle ,point1,point2 dx = point2 - point1 dy = point2 - point1 IF dx EQ 0 THEN BEGIN ; x轴 IF dy GT 0 THEN result = !PI/2 ELSE $ result = 3*!PI/2 ENDIF ELSE BEGIN IF dy EQ 0 THEN BEGIN ;x轴 IF dx GT 0 THEN result = 0 ELSE $ result = !PI ENDIF ElSE BEGIN result = ATAN(dy/dx) IF result GT 0 THEN IF dx LT 0 THEN result = result +!Pi IF result LT 0 THEN IF dx LT 0 THEN result = result +!Pi ELSE $ result = result + 2*!PI ENDELSE END return,result MOD (2*!PI) END
图像预处理 DWT fusion sharpen multispectral images with discrete wavelet transform A trous fusion ditto with a trous wavelet transform Wang-Bovik quality index evaluate radiometric fidelity of pansharpened images C-correction correct for solar illumination in rough terrain Kernel PCA perform nonlinear principal components analysis (can take advantage of GPULib) Kernel MAF perform nonlinear maximum autocorrelation factor analysis (can take advantage of GPULib) Contour-match get tie-points for image-image registration from invariant features 监督分类 Bayes maximum likelihood wrapper for the ENVI ML classifier Support vector machine wrapper for the ENVI SVM classifier Hybrid two-layer neural network trained with kalman filter and scaled conjugate gradient algorithms Two-layer neural network trained with scaled conjugate gradient algorithm (can take advantage of GPULib) Boosted three-layer neural network apply adaptive boosting (AdaBoost) to a sequence of neural networks Gaussian kernel classification non-parametric Parzen-window classification (can take advantage of GPULib) Probabilistic label relaxation perform postclassification filtering Contingency table calculate confusion matrices and kappa values McNemar test compare classifiers with the McNemar statistic 非监督分类 Expectation maximization cluster image data with a mixture of multivariate Gaussians (can take advantage of GPULib) FKM clustering cluster image data with a fuzzy K-means algorithm HCL clustering cluster image data with a heirarchic agglomerative algorithm Kernel K-means cluster image data with a kernel version of K-means (can take advantage of GPULib) Kohonen SOM visualize image data with the Kohonen self-organizing map Mean shift segment images with mean-shift algorithm 变化监测 IR-MAD (iMAD) apply iteratively re-weighted multivariate alteration detection Radcal perform automatic relative radiometric normalization of images MadView set thresholds on MAD images 其他 Structure height use RFMs to determine height of vertical structures Class segmentation Segment a classified image Examples example IDL programs from the 2nd edition Solutions some solutions to the progamming exercises in the 2nd edition CUDA (experimental) Cuda_SVD a DLM for singular value decomposition on CUDA Cuda_NDVI a DLM for calculating NDVI indices on CUDA Cuda_STRETCH a DLM for enhacement stretching on CUDA 【转自】http://mcanty.homepage.t-online.de/index.html