@@ -0,0 +1,11 | |||||
|
1 | ||||
|
2 | subroutine get_len(the_len,fqual_temp) | |||
|
3 | c | |||
|
4 | c create table of magnetic field components | |||
|
5 | c | |||
|
6 | c character*47 L | |||
|
7 | ||||
|
8 | character(1024) :: fqual_temp | |||
|
9 | character(512) :: ppath | |||
|
10 | character(512) :: cpath | |||
|
11 | integer the_len |
@@ -0,0 +1,24 | |||||
|
1 | ||||
|
2 | fqual_temp = TRIM(ppath)//TRIM(cpath) | |||
|
3 | the_len = LEN_TRIM(fqual_temp) | |||
|
4 | ||||
|
5 | return | |||
|
6 | end | |||
|
7 | ||||
|
8 | subroutine get_path(fqual,the_len) | |||
|
9 | c | |||
|
10 | c create table of magnetic field components | |||
|
11 | c | |||
|
12 | c character*47 L | |||
|
13 | ||||
|
14 | integer the_len | |||
|
15 | character(the_len) :: fqual | |||
|
16 | character(1024) :: fqual_temp | |||
|
17 | ||||
|
18 | call get_len(the_len,fqual_temp) | |||
|
19 | fqual = TRIM(fqual_temp) | |||
|
20 | write(*,*) "Done" | |||
|
21 | ||||
|
22 | return | |||
|
23 | end | |||
|
24 |
@@ -89,14 +89,20 setup( | |||||
89 |
|
89 | |||
90 | main_path = os.getcwd() |
|
90 | main_path = os.getcwd() | |
91 | child_path = '/schainf/Ffiles/bfmodel/' |
|
91 | child_path = '/schainf/Ffiles/bfmodel/' | |
|
92 | child_path_r = '/schainf/Ffiles/jlib26feb2001' | |||
92 | #print("main_path: ", main_path) |
|
93 | #print("main_path: ", main_path) | |
93 | my_str = ' '+"ppath = "+"\""+main_path+"\"\n" |
|
94 | my_str = ' '+"ppath = "+"\""+main_path+"\"\n" | |
94 | my_str_2 = ' '+"cpath = "+"\""+child_path+"\"" |
|
95 | my_str_2 = ' '+"cpath = "+"\""+child_path+"\"" | |
|
96 | my_str_2_r = ' '+"cpath = "+"\""+child_path_r+"\"" | |||
95 |
|
97 | |||
96 | #''' |
|
98 | #''' | |
97 | with open('./schainf/Ffiles/get_path_1.f', 'r') as path1: data1 = path1.read() |
|
99 | with open('./schainf/Ffiles/get_path_1.f', 'r') as path1: data1 = path1.read() | |
98 | with open('./schainf/Ffiles/get_path_2.f', 'r') as path2: data2 = path2.read() |
|
100 | with open('./schainf/Ffiles/get_path_2.f', 'r') as path2: data2 = path2.read() | |
99 | with open('./schainf/Ffiles/get_path.f', 'w') as final: final.write(data1+my_str+my_str_2+data2) |
|
101 | with open('./schainf/Ffiles/get_path.f', 'w') as final: final.write(data1+my_str+my_str_2+data2) | |
|
102 | ||||
|
103 | with open('./schainf/Ffiles/get_path_1_reader.f', 'r') as p1: data1_r = p1.read() | |||
|
104 | with open('./schainf/Ffiles/get_path_2_reader.f', 'r') as p2: data2_r = p2.read() | |||
|
105 | with open('./schainf/Ffiles/get_path_reader.f', 'w') as final_r: final_r.write(data1_r+my_str+my_str_2_r+data2_r) | |||
100 | #''' |
|
106 | #''' | |
101 |
|
107 | |||
102 | from numpy.distutils.core import Extension, setup |
|
108 | from numpy.distutils.core import Extension, setup |
General Comments 0
You need to be logged in to leave comments.
Login now