Linux 板


LINE

以下是soem大的回應 還有我的問題 (徵得soem大同意附上) ※ 引述《flied (libertines)》之銘言: : ※ 引述《soem (流水)》之銘言: : : 這應該就是可以直接call得到talys指令了 : : 這是之前的文章 : : 這是後來你執行的狀況 : : 請注意妳現在的所在目錄, : : 比對兩次結果,你是不是該去 ~/physics/talys/samples 尋找你的verify : : 雖然不知道為甚麼你會在/bin裡面,姑且推論一下你的想法好了: : : 1. 你可能認為執行檔要在/bin底下才能跑? : : => 實際上不用,跟檔案權限有關系 : : 但要注意的是,如果你要執行的不是在系統$PATH裡面的程式, : : 要用相對或絕對路徑的方式去呼叫。 : : 像是你在 ~/physics/talys/samples裡面呼叫相對路徑 "./": : : ~/physics/talys/samples$ ./verify : : 或是絕對路徑 : : /home/你的帳號/physics/talys/samples/verify : : 若是你直接呼叫verify,就是呼叫到系統預先有的那隻verify工具。 : : 2. 你可能不確定chmod的功能以及"bash: ./verify: 拒絕不符權限的操作"的成因 : : => 首先無論是script或程式一般來說都需要檔案權限才能執行; : : 這邊的權現有兩個面向:你的權限,和設定給檔案的權限。 : : 我們先來看看一般權限的呈現方式: : : $ ls -ld /bin/bash : : -rwxr-xr-x 1 root root 959120 Mar 29 2013 /bin/bash : : 第一組rwx是這個檔案的擁有者root所能做的事情 : : read, write, execute : : 第二組rwx是這個檔案的擁有者群組,root群組所能做的事情 : : 所以有在root群組且非使用者root則會參考這組設定 : : 第三組rwx則是除此以外的人的權限。 : : 所以說,我們可以看到/bin/bash這個檔案, : : - 擁有者root具有所有權限; : : - 擁有者群組root沒有修改(寫入)的權限,但可以讀取和執行; : : - 剩下的人亦是沒有修改、有讀取執行的權限。 : : 一般的文字檔案類型往往是644,例如: : : $ ls -ld /etc/hosts : : -rw-r--r-- 1 root root 342 Jan 22 20:16 /etc/hosts : : 我想你的~/physics/talys/samples/verify應該也是類似的情形, : : 因此你需要的是幫他加上execute : : ~/physics/talys/samples/$ chmod +x verify : : sudo 可以幫你取得不同使用者的權限,但針對x這項設定通常需要用chmod來調整。 : 謝謝 : 我執行了這行成功 : lee@lee-X402CA:~/physics/talys/samples$ ./verify : bash: ./verify: 拒絕不符權限的操作 : lee@lee-X402CA:~/physics/talys/samples$ chmod +x verify : lee@lee-X402CA:~/physics/talys/samples$ ./verify : /home/lee/physics/talys/samples/17/a/new : /home/lee/physics/talys/samples/17/b/new : /home/lee/physics/talys/samples/17/c/new : /home/lee/physics/talys/samples/11/new : /home/lee/physics/talys/samples/10/a/new : /home/lee/physics/talys/samples/10/b/new : /home/lee/physics/talys/samples/20/new : /home/lee/physics/talys/samples/1/f/new : /home/lee/physics/talys/samples/1/g/new : /home/lee/physics/talys/samples/1/e/new : /home/lee/physics/talys/samples/1/h/new : /home/lee/physics/talys/samples/1/a/new : /home/lee/physics/talys/samples/1/b/new : /home/lee/physics/talys/samples/1/d/new : /home/lee/physics/talys/samples/1/i/new : /home/lee/physics/talys/samples/1/c/new : /home/lee/physics/talys/samples/8/new : /home/lee/physics/talys/samples/21/new : /home/lee/physics/talys/samples/3/a/new : /home/lee/physics/talys/samples/3/b/new : /home/lee/physics/talys/samples/3/d/new : /home/lee/physics/talys/samples/3/c/new : /home/lee/physics/talys/samples/22/new : /home/lee/physics/talys/samples/9/new : /home/lee/physics/talys/samples/6/a/new : /home/lee/physics/talys/samples/6/b/new : /home/lee/physics/talys/samples/19/new : /home/lee/physics/talys/samples/16/a/new : /home/lee/physics/talys/samples/16/b/new : /home/lee/physics/talys/samples/16/d/new : /home/lee/physics/talys/samples/16/c/new : /home/lee/physics/talys/samples/2/new : /home/lee/physics/talys/samples/24/new : /home/lee/physics/talys/samples/25/new : /home/lee/physics/talys/samples/12/new : /home/lee/physics/talys/samples/23/new : /home/lee/physics/talys/samples/14/new : /home/lee/physics/talys/samples/5/new : /home/lee/physics/talys/samples/15/new : /home/lee/physics/talys/samples/18/a/new : /home/lee/physics/talys/samples/18/b/new : /home/lee/physics/talys/samples/4/a/new : /home/lee/physics/talys/samples/4/b/new : /home/lee/physics/talys/samples/13/new : /home/lee/physics/talys/samples/7/new : 似乎成功 : 但readme如下 : Verification : ------------ : - cd samples : - verify : Under Linux/Unix, this should run all sample cases (about 1 hour on : a fast PC). : 我這大概3秒就結束 : 所以應該還沒有裝好 : : 這邊就只是你的系統有安裝一個叫做verify的指令, : : 但這你的使用經驗看來,那個指令並不是你這次安裝的步驟中需要呼叫到的。 : Your own calculations : --------------------- : - talys < input > output : where you can make your own input file starting from the many sample cases : we provide. : 我試著計算執行 : 錯誤如下 : lee@lee-X402CA:~/physics/talys/test$ talys input output5 soem: 先說這行: $ talys < input > output < :把檔案讀進stdin > :把s "如果"我沒有誤會他的readme的話,這行命令是: 1. 應該是要你準備個名叫input且符合他的格式的input檔案 2. 然後,會輸出結果到output檔案 格式的話,照他readme這句是他有提供一些sample可以參考。 不曉得你下面的input是不是有照這個方式呢? (不過你得到的錯誤訊息是下面那件事情) me: 我的input是直接從sample複製貼上到test資料夾 所以格式內容是一模一樣 : TALYS-error: Structure database not installed: change path in machine.f : 我的machine.f 在 /home/lee/physics/talys/source : https://www.dropbox.com/s/zmbhzustk6hnp6v/2014-01-26%2021%3A39%3A35.png
: 內容如下 : https://www.dropbox.com/s/yq6o4hbraqftuf6/2014-01-26%2021%3A32%3A21.png
因為我看不懂fortran所以只能用猜的... 他似乎是需要...嗯...可能是 home/structure/abundance/z001 那個home就是你改的變數,看看該路徑是不是有這個檔案。 有 https://www.dropbox.com/s/e46dmelae22v3jw/2014-01-27%2009%3A49%3A55.png
: c ********************* Set directory for structure data *************** : c : c path : directory containing structure files to be read : c lenpath: length of pathname : c : c The maximum length of the path is 60 characters : c : home='/home/lee/physics/talys/' (我改這行) : lenhome=0 : do 10 i=1,60 : if (home(i:i).eq.' ') goto 100 : lenhome=lenhome+1 : 10 continue : 100 path=home(1:lenhome)//'structure/' : lenpath=lenhome+10 : c : c Test to check accessibility of structure files : c : inquire (file=path(1:lenpath)//'abundance/z001',exist=lexist) : if (lexist) return : write(*,'(" TALYS-error: Structure database not installed:", : + " change path in machine.f")') : stop : end : Copyright (C) 2013 A.J. Koning, S. Hilaire and S. Goriely : 我改的只有這部份 : 原本是 home='.' : 不能執行後,我改成 : home='/home/lee/physics/talys/' : 這樣改對吧? soem : 之前FedoraHanT給的hint中這行: sed -i 's|/home/finux01b/akoning/talys/|.|' machine.f 就是把他換成 '.' me: 所以原本的 home='.' 是對的? 但我改回 執行的錯誤一樣 TALYS-error: Structure database not installed: change path in machine.f soem : 不過更重要的是,fortan是要重新compile的喔! 所以你改過之後也得重新compile出新的執行檔才有用。 me: 抱歉,我是超弱手,這邊要如何compile? ※ 編輯: flied 來自: 61.220.220.27 (01/27 10:53)







like.gif 您可能會有興趣的文章
icon.png[問題/行為] 貓晚上進房間會不會有憋尿問題
icon.pngRe: [閒聊] 選了錯誤的女孩成為魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一張
icon.png[心得] EMS高領長版毛衣.墨小樓MC1002
icon.png[分享] 丹龍隔熱紙GE55+33+22
icon.png[問題] 清洗洗衣機
icon.png[尋物] 窗台下的空間
icon.png[閒聊] 双極の女神1 木魔爵
icon.png[售車] 新竹 1997 march 1297cc 白色 四門
icon.png[討論] 能從照片感受到攝影者心情嗎
icon.png[狂賀] 賀賀賀賀 賀!島村卯月!總選舉NO.1
icon.png[難過] 羨慕白皮膚的女生
icon.png閱讀文章
icon.png[黑特]
icon.png[問題] SBK S1安裝於安全帽位置
icon.png[分享] 舊woo100絕版開箱!!
icon.pngRe: [無言] 關於小包衛生紙
icon.png[開箱] E5-2683V3 RX480Strix 快睿C1 簡單測試
icon.png[心得] 蒼の海賊龍 地獄 執行者16PT
icon.png[售車] 1999年Virage iO 1.8EXi
icon.png[心得] 挑戰33 LV10 獅子座pt solo
icon.png[閒聊] 手把手教你不被桶之新手主購教學
icon.png[分享] Civic Type R 量產版官方照無預警流出
icon.png[售車] Golf 4 2.0 銀色 自排
icon.png[出售] Graco提籃汽座(有底座)2000元誠可議
icon.png[問題] 請問補牙材質掉了還能再補嗎?(台中半年內
icon.png[問題] 44th 單曲 生寫竟然都給重複的啊啊!
icon.png[心得] 華南紅卡/icash 核卡
icon.png[問題] 拔牙矯正這樣正常嗎
icon.png[贈送] 老莫高業 初業 102年版
icon.png[情報] 三大行動支付 本季掀戰火
icon.png[寶寶] 博客來Amos水蠟筆5/1特價五折
icon.pngRe: [心得] 新鮮人一些面試分享
icon.png[心得] 蒼の海賊龍 地獄 麒麟25PT
icon.pngRe: [閒聊] (君の名は。雷慎入) 君名二創漫畫翻譯
icon.pngRe: [閒聊] OGN中場影片:失蹤人口局 (英文字幕)
icon.png[問題] 台灣大哥大4G訊號差
icon.png[出售] [全國]全新千尋侘草LED燈, 水草

請輸入看板名稱,例如:BabyMother站內搜尋

TOP