게시판 답변이 생성됐습니다
-
글쓴이글
-
안녕하세요
또 다른 방법 한가지를 더 소개해 보겠습니다.
아래 첨부한 코드 중 rebin_img를 사용하는 것인데요,
rebin_img 코드는 사용자가 넣어준 데이터를 균일한 간격으로 선형 내삽해주는 코드입니다.
data는 첨부해주신 데이터의 spectrum에 해당되는 것이고, x, y 각각 time과 frequency에 해당됩니다.
xdim, ydim 은 rebin_img 에의해 선형 내삽된 이미지의 새로운 dimension이며, 이 값들은 적당한 값을 임의로 주시면 될 듯 합니다.
사용법은 test6 코드에 간단히 적혀 있구요.
간단한 코드이기에 따로 설명하지 않아도 코드를 보시면 내용을 금방 파악하실 수 있을 것입니다.function rebin_img, data, x, y, xdim=xdim, ydim=ydim
!null = histogram([min(x), max(x)], nbins=xdim, loc=xloc)
!null = histogram([min(y), max(y)], nbins=ydim, loc=yloc)xidx = interpol(dindgen(n_elements(x)), x, xloc)
yidx = interpol(dindgen(n_elements(y)), y, yloc)intp_data = interpolate(double(data), xidx, yidx, /grid, missing=!values.f_nan)
return, {data:intp_data, xaxis:xloc, yaxis:yloc}
end
pro test6
restore, ‘data’
out = rebin_img(spectrum, time, frequency, xdim=400, ydim=400)
dum=label_date(date_format=’%h:%I’)
i = image(out.data, out.xaxis, out.yaxis, $
axis=1, $
aspect_ratio = 0, $
pos = [0.1, 0.1, 0.9, 0.9], $
ytitle = ‘Freq’, $
xtitle = ‘Jul’, $
xtickformat=’label_date’, $
rgb_table = 33)end
안녕하세요.
아래 코드 참고하시면 도움이 될 듯 합니다.1234567891011121314151617;; frequency 가 0 인곳 삭제fx = fx[*, 1:*]freq = freq[1:*]dim = fx.dim;; log space 에서 균일한 간격을 같는 frequency 생성log_y = alog10(freq)new_y = findgen(dim[1]) / (dim[1]-1) * (log_y[-1] - log_y[0]) + log_y[0];; 새로 만들어진 log(frequency) 축에 맞게 fx를 interpolateyidx = interpol(findgen(dim[1]), log_y, new_y)new_data = interpolate(fx, findgen(dim[0]), yidx, /grid)i = image(new_data, time, new_y, rgb_table=33, axis_style=2, aspect_ratio=0, pos=[0.1,0.1,0.9,0.9], /ylog)만일 fx를 interpolation할 때 linear 가 아닌 spline 과 같은 interpolation 방법이 필요하다면 interpolate 함수 대신 interpol 함수를 적용하시면 될 것 입니다.
- 이 답변은 tlseorb0111에 의해 6 years, 1 month 전에 수정됐습니다.
안녕하세요
IDL 외부 라이브러리에 N-D interpolation을 지원하는 함수가 있는지는 잘 모르겠습니다만, 제 생각에 가장 간단한 방법은 python을 연동시켜 사용하는 것입니다.
python 의 scipy 에 N-D interpolation을 지원하는 함수가 몇가지 있으니 필요하신 함수를 IDL 로 불러와 사용하실 수 있습니다.
만일 python이 익숙하지 않으시고 선형 내삽만으로 충분하시다면, Look-Up-Table 의 차원을 하나씩 줄여가면서 interpolation 하는 방법이 있습니다. 아래에 예제 코드 입니다.
아래의 코드가 가장 효율적인지는 모르겠으나 예제를 보시면 아이디어를 얻으 실 수도 있을 것 같습니다.123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566function gg, naxis = randomu(seed, n, /double)axis = axis.sort()axis -= axis[0]axis /= axis[-1]return, axisendfunction lin_interp_5d, data, a1, a2, a3, a4, a5, $na1, na2, na3, na4, na5dim = data.dimtmp1 = dblarr(dim[1])tmp2 = dblarr(dim[2])tmp3 = dblarr(dim[3])tmp4 = dblarr(dim[4])for i = 0, dim[4] - 1 do beginfor j = 0, dim[3] - 1 do beginfor k = 0, dim[2] - 1 do beginfor l = 0, dim[1] - 1 do begintmp1[l] = interpol(data[*, l, k, j, i], a1, na1)endfortmp2[k] = interpol(tmp1, a2, na2)endfortmp3[j] = interpol(tmp2, a3, na3)endfortmp4[i] = interpol(tmp3, a4, na4)endforreturn, interpol(tmp4, a5, na5)endpro test1;; look up table의 5차원 축의 dimensiondim = [10, 4, 11, 13, 5];; look up table의 축 다섯개a1 = gg(dim[0])a2 = gg(dim[1])a3 = gg(dim[2])a4 = gg(dim[3])a5 = gg(dim[4]);; look up table datadata = randomu(seed, dim, /double);; interpolation 하여 뽑아낼 축 다섯개.na1 = randomu(seed, 1, /double)na2 = randomu(seed, 1, /double)na3 = randomu(seed, 1, /double)na4 = randomu(seed, 1, /double)na5 = randomu(seed, 1, /double);; 새로운 5개 축의 linear interpolationout = lin_interp_5d(data, a1, a2, a3, a4, a5, $na1, na2, na3, na4, na5)print, outend- 이 답변은 tlseorb0111에 의해 6 years, 2 months 전에 수정됐습니다.
- 이 답변은 tlseorb0111에 의해 6 years, 2 months 전에 수정됐습니다.
안녕하세요.
제가 알기로는 IDL은 python이나 openmp처럼 쉽게(?) 병렬 처리를 할 수 있는 방법은 따로 없는거로 알고있습니다.
다만 idl_bridge를 활용해서 multi processing 작업을 할 수 있는데요
저는 개인적으로 http://www.iluvatar.org/~dwijn/parallelidl 에서 많은 도움을 받았습니다.
idl_bridge 를 쉽게 쓸 수 있도록 여러가지 함수들도 제공하고 있으니 한번 둘러보셔도 좋을 것 같습니다.추가로
i = surface(/test) 를 한 후 생성된 그림에서 ctrl+c 를 하면 클립보드로 그림이 복사되는 것으로 알고 있습니다.ctrl+c를 surface 함수 사용 후 하면 idl이 꺼집니다. 위 경우와 마친가지로 image, contour, plot 등은 제대로 작동합니다.
답변 감사합니다.
사용한 코드는
i = surface(/test)
i.save, ‘123.png’입니다. png 뿐 아니라 eps, jpg 등도 모두 그림은 잘 그려지지만 저장이 되질 않고 idl 이 꺼지고 있습니다.
image나 contour 같은 함수는 모두 제대로 저장이 됩니다. width키워드를 넣어봐도 만찬가지 증상이 나타납니다.
언제부터 이런 증상이 있었는지는 잘 기억이 나질 않습니다. surface 함수를 쓸 일이 많지 않아서요.
idl의 버전은 8.5.1 입니다.
답변 감사합니다.
말씀해주신 bitmap 키워드를 사용하면 그림이 제대로 저장됩니다.
하지만 제가 필요한 것은 vector라 bitmap 키워드는 적절하지 않은 것같습니다.
IDL 8 버전 초반 부터 pdf 저장은 자잘한 버그가 몇 있었는데 아직 많이 수정이 안된 것 같습니다.
답변 갑사합니다.
우분투 14.04 에서는 따로 path 설정을 해주지 않아도 idl 에서 python이 사용 가능한데
우분투 12.04 에서는 적어주신 path를 설정해 줘야 idl 에서 python 이 사용 가능합니다.또 우분투 14.04 의 경우 아래와 같이 path를 .bashrc에 추가한 뒤
export LD_LIBRARY_PATH=”$LD_LIBRARY_PATH:/usr/lib”
export LD_LIBRARY_PATH=”$LD_LIBRARY_PATH:/home/daekyu/anaconda2/lib”
export LD_LIBRARY_PATH=”$LD_LIBRARY_PATH:/usr/local/exelis/idl85/bin/bin.linux.x86_64″export PYTHONHOME=”/home/daekyu/anaconda2″
export PYTHONPATH=”$PYTHONPATH:/usr/local/exelis/idl85/bin/bin.linux.x86_64″
export PYTHONPATH=”$PYTHONPATH:/usr/local/exelis/idl85/lib/bridges”Python 내에서 from idlpy import IDL 명령어는 별문제 없이 실행되는 것 같습니다.
idl 내에서 python bridge의 다은 명령어들 예를 들어 numpy를 사용한다던가.. 하는 것들은 모두 문제 없이 되는 것 같습니다.
다만 idl 내에서 python bridge 후 ncdf 파일을 열때 튕기는 경우, 이것도 python bridge 를 사용하기 전 idl에서 dlm_load, ‘ncdf’ 사용 후 ncdf 파일을 읽으면 정상 적으로 읽히지만 .FULL_RESET_SESSION을 사용할 경우 또 튕깁니다. (.RESET_SESSION 은 튕기지 않습니다.)
같은 버전의 idl과 anaconda를 사용해 윈도우에서 작업을 할 경우는 문제가 없습니다.
답변 감사드립니다
아래 내용은 터미널에서 printenv를 사용했을때 나오는 것을 붙여넣기 한 것입니다.CLHEP_LIB_DIR=/home/daekyu/Documents/clhep/lib
G4LEVELGAMMADATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/PhotonEvaporation2.3
MKLROOT=/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl
XDG_VTNR=7
MANPATH=/opt/intel/man/common:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/man:/opt/intel/compilers_and_libraries_2016.1.150/linux/man/en_US:/opt/intel/documentation_2016/en/debugger//gdb-ia/man/:/opt/intel/documentation_2016/en/debugger//gdb-mic/man/:/opt/intel/documentation_2016/en/debugger//gdb-igfx/man/:/opt/intel/man/common:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/man:/opt/intel/compilers_and_libraries_2016.1.150/linux/man/en_US:/opt/intel/documentation_2016/en/debugger//gdb-ia/man/:/opt/intel/documentation_2016/en/debugger//gdb-mic/man/:/opt/intel/documentation_2016/en/debugger//gdb-igfx/man/:/home/daekyu/anaconda2/share/man:/usr/local/man:/usr/local/share/man:/usr/share/man:
XDG_SESSION_ID=c2
CLUTTER_IM_MODULE=xim
SELINUX_INIT=YES
XDG_GREETER_DATA_DIR=/var/lib/lightdm-data/daekyu
SESSION=ubuntu
G4ROOT=/home/daekyu/Documents/geant4
INTEL_LICENSE_FILE=/opt/intel/compilers_and_libraries_2016.1.150/linux/licenses:/opt/intel/licenses:/home/daekyu/intel/licenses:/opt/intel/compilers_and_libraries_2016.1.150/linux/licenses:/opt/intel/licenses:/home/daekyu/intel/licenses
IPPROOT=/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp
GPG_AGENT_INFO=/run/user/1000/keyring-rfh3zQ/gpg:0:1
G4INSTALL=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/geant4make
TERM=xterm
SHELL=/bin/bash
XDG_MENU_PREFIX=gnome-
VTE_VERSION=3409
GDBSERVER_MIC=/opt/intel/debugger_2016/gdb/targets/mic/bin/gdbserver
LIBRARY_PATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/intel64/gcc4.4:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../compiler/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/intel64/gcc4.4:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../tbb/lib/intel64_lin/gcc4.4:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../compiler/lib/intel64_lin
QTHOME=/home/daekyu/anaconda2
G4INCLUDE=/home/daekyu/Documents/geant4/include/Geant4
CDF_BASE=/usr/local/cdf
WINDOWID=18874379
UPSTART_SESSION=unix:abstract=/com/ubuntu/upstart-session/1000/1980
GNOME_KEYRING_CONTROL=/run/user/1000/keyring-rfh3zQ
G4NEUTRONXSDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/G4NEUTRONXS1.2
MIC_LD_LIBRARY_PATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/mic
GTK_MODULES=overlay-scrollbar:unity-gtk-module
QTLIBS=-L/usr/lib -lQtCore -lQtGui
CDF_BIN=/usr/local/cdf/bin
G4LEDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/G4EMLOW6.32
USER=daekyu
G4VIS_USE_OPENGLQT=1
LD_LIBRARY_PATH=/home/daekyu/Documents/clhep/lib:/home/daekyu/Documents/geant4/lib:/home/daekyu/Documents/geant4/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/intel64/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/intel64/gcc4.4:/opt/intel/debugger_2016/libipt/intel64/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../compiler/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/intel64/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/intel64/gcc4.4:/opt/intel/debugger_2016/libipt/intel64/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/intel64_lin:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../tbb/lib/intel64_lin/gcc4.4:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/../compiler/lib/intel64_lin
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lz=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.axa=00;36:*.oga=00;36:*.spx=00;36:*.xspf=00;36:
QTFLAGS=-I/usr/include/qt4 -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtOpenGL
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session0
MIC_LIBRARY_PATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/mic:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/mic/lib:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/lib/mic
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
G4NEUTRONHPDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/G4NDL4.2
CPATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/ipp/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb/include:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/include
SSH_AUTH_SOCK=/run/user/1000/keyring-rfh3zQ/ssh
G4RADIOACTIVEDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/RadioactiveDecay3.6
CDF_INC=/usr/local/cdf/include
SESSION_MANAGER=local/ubuntu:@/tmp/.ICE-unix/2136,unix/ubuntu:/tmp/.ICE-unix/2136
DEFAULTS_PATH=/usr/share/gconf/ubuntu.default.path
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/usr/share/upstart/xdg:/etc/xdg
NLSPATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64/locale/%l_%t/%N:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64/locale/%l_%t/%N:/opt/intel/debugger_2016/gdb/intel64_mic/share/locale/%l_%t/%N:/opt/intel/debugger_2016/gdb/intel64/share/locale/%l_%t/%N:/opt/intel/compilers_and_libraries_2016.1.150/linux/compiler/lib/intel64/locale/%l_%t/%N:/opt/intel/compilers_and_libraries_2016.1.150/linux/mkl/lib/intel64/locale/%l_%t/%N:/opt/intel/debugger_2016/gdb/intel64_mic/share/locale/%l_%t/%N:/opt/intel/debugger_2016/gdb/intel64/share/locale/%l_%t/%N
CDF_HELP=/usr/local/cdf/lib/cdf/help
PATH=/home/daekyu/geant4_workdir/bin/Linux-g++:/home/daekyu/Documents/geant4/bin:/opt/intel/compilers_and_libraries_2016.1.150/linux/bin/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/intel64/bin:/opt/intel/debugger_2016/gdb/intel64_mic/bin:/opt/intel/compilers_and_libraries_2016.1.150/linux/bin/intel64:/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi/intel64/bin:/opt/intel/debugger_2016/gdb/intel64_mic/bin:/home/daekyu/anaconda2/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
DESKTOP_SESSION=ubuntu
GLQTLIBS=-L/usr/lib -lQtCore -lQtGui -lQtOpenGL
G4LIB=/home/daekyu/Documents/geant4/lib/Geant4-9.6.4
G4ROOTMAKE=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/geant4make
QT_IM_MODULE=ibus
QT_QPA_PLATFORMTHEME=appmenu-qt5
TBBROOT=/opt/intel/compilers_and_libraries_2016.1.150/linux/tbb
G4LIB_BUILD_SHARED=1
G4PIIDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/G4PII1.3
CDF_LIB=/usr/local/cdf/lib
JOB=dbus
PWD=/home/daekyu
XMODIFIERS=@im=ibus
CLHEP_BASE_DIR=/home/daekyu/Documents/clhep
GDB_CROSS=/opt/intel/debugger_2016/gdb/intel64_mic/bin/gdb-mic
CDF_JAVA=/usr/local/cdf/cdfjava
GNOME_KEYRING_PID=1976
LANG=en_US.UTF-8
GDM_LANG=en_US
MANDATORY_PATH=/usr/share/gconf/ubuntu.mandatory.path
QTMOC=/usr/bin/moc-qt4
IM_CONFIG_PHASE=1
COMPIZ_CONFIG_PROFILE=ubuntu
G4SAIDXSDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/G4SAIDDATA1.1
DAALROOT=/opt/intel/compilers_and_libraries_2016.1.150/linux/daal
GDMSESSION=ubuntu
G4VIS_USE_OPENGLX=1
MPM_LAUNCHER=/opt/intel/debugger_2016/mpm/mic/bin/start_mpm.sh
G4UI_USE_TCSH=1
INTEL_PYTHONHOME=/opt/intel/debugger_2016/python/intel64/
SESSIONTYPE=gnome-session
G4VIS_USE_RAYTRACERX=1
CLHEP_INCLUDE_DIR=/home/daekyu/Documents/clhep/include
XDG_SEAT=seat0
HOME=/home/daekyu
SHLVL=1
G4SYSTEM=Linux-g++
G4REALSURFACEDATA=/home/daekyu/Documents/geant4/share/Geant4-9.6.4/data/RealSurface1.0
LANGUAGE=en_US
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
G4UI_USE_QT=1
PYTHONPATH=/usr/local/lib/python2.7/site-packages/:
LOGNAME=daekyu
COMPIZ_BIN_PATH=/usr/bin/
CLASSPATH=/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/daal.jar:/opt/intel/compilers_and_libraries_2016.1.150/linux/daal/lib/daal.jar
XDG_DATA_DIRS=/usr/share/ubuntu:/usr/share/gnome:/usr/local/share/:/usr/share/
QT4_IM_MODULE=xim
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-pJOaGEEtR4
G4WORKDIR=/home/daekyu/geant4_workdir
PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
CDF_LEAPSECONDSTABLE=/usr/local/cdf/CDFLeapSeconds.txt
LESSOPEN=| /usr/bin/lesspipe %s
QTLIBPATH=/home/daekyu/anaconda2/lib
INFOPATH=/opt/intel/documentation_2016/en/debugger//gdb-ia/info/:/opt/intel/documentation_2016/en/debugger//gdb-mic/info/:/opt/intel/documentation_2016/en/debugger//gdb-igfx/info/:/opt/intel/documentation_2016/en/debugger//gdb-ia/info/:/opt/intel/documentation_2016/en/debugger//gdb-mic/info/:/opt/intel/documentation_2016/en/debugger//gdb-igfx/info/
INSTANCE=
TEXTDOMAIN=im-config
XDG_RUNTIME_DIR=/run/user/1000
DISPLAY=:0
XDG_CURRENT_DESKTOP=Unity
GTK_IM_MODULE=ibus
LESSCLOSE=/usr/bin/lesspipe %s %s
G4LIB_USE_ZLIB=1
TEXTDOMAINDIR=/usr/share/locale/
I_MPI_ROOT=/opt/intel/compilers_and_libraries_2016.1.150/linux/mpi
COLORTERM=gnome-terminal
XAUTHORITY=/home/daekyu/.Xauthority
_=/usr/bin/printenvUbuntu 는 Ubuntu 14.04.4와 12.04.5 입니다.
Python, Anaconda 버전은 Python 2.7.11 :: Anaconda 4.0.0 (64-bit)
IDLDE, 터미널 모두 나타납니다.
많은 경우를 해본 것이 아니라 자세히는 모르지만
idl 내에서 python bridge를 사용후 ncdf_open() 함수를 사용하면 모두
Segmentation fault (core dumped) 가 나타납니다.ncdf_open() 을 사용 후 python bridge를 사용하면 문제 없이 됩니다.
ncdf_open()->python bridge-> ncdf_open() 도 문제 없이 발생하구요.
python bridge -> ncdf_open() 의 경우만 에러가 발생하는 것 같습니다.Ubuntu 14, 12 에서
python bridge를 실행하기 전에 dlm_load, ‘ncdf’를 실행해주면 정상적으로 ncdf_open 이 작동합니다.ncdf_open 이 후 .full_reset을 할 경우 또 튕깁니다. .reset 은 안 튕기네요.
문제가 뭘까요…
답변 감사합니다.
굉장히 많은 도움이 되었습니다.
답변 감사합니다.
f90으로 바꿔서 해봐도 같은 증상이 발생합니다.
컴파일러를 cygwin에서 mingw64로 바꿔서하니 문제가 해결 됐습니다.
cygwin문제인것 같은데 자세한 것은 잘 모르겠네요…..
- 이 답변은 tlseorb0111에 의해 8 years, 5 months 전에 수정됐습니다.
답변 감사합니다.
많은 도움이 돼었습니다.
해결 방법을 찾았습니다.
.run /home/daekyu/test.pro 후에
test 를 더 써줘야 실행이 되는군요.
제가 사용법을 잘못 알고 있었나 보네요 -
글쓴이글