Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
tao authored and tao committed Jun 14, 2018
1 parent f94e131 commit 8281dc5
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/e_2_xyz.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def replicate(xyz_info, args):
b.step = i
toPdb(b, "output%05d.pdb"%i)
# replicate the box using external code (genconf in Gromacs)
subprocess.Popen(["genconf", "-f", "output%05d.pdb"%i,
subprocess.Popen(["gmx", "genconf", "-f", "output%05d.pdb"%i,
"-o", "s_%05d.pdb"%i, "-nbox",
"%d"%na, "%d"%nb, "%d"%nc],
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
Expand Down
4 changes: 2 additions & 2 deletions tools/Lammps/getInput.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
LIB = "/net/hulk/home6/chengtao/soft/simpy/lib"
elif socket.gethostname() == "zwicky":
LIB = "/home/tcheng/Soft/simpy/lib"
elif socket.gethostname() == "tao-Precision-Tower-3420":
LIB = "/home/tao/Soft/simpy/lib"
elif socket.gethostname() == "tao-Precision-Tower-3420-ubuntu":
LIB = "/home/tao/soft/simpy/lib"
elif "node" in socket.gethostname():
LIB = "/net/hulk/home6/chengtao/soft/simpy/lib"
elif socket.gethostname() == "tao-ThinkCentre-M79":
Expand Down
10 changes: 10 additions & 0 deletions tools/linux/resize.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
convert slice-0.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-00.png
convert slice-1.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-01.png
convert slice-2.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-02.png
convert slice-3.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-03.png
convert slice-4.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-04.png
convert slice-5.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-05.png
convert slice-6.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-06.png
convert slice-7.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-07.png
convert slice-8.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-08.png
convert slice-9.png -resize 800x400 -background 'rgb(255,255,255)' -compose Copy -gravity center -extent 300x300 re-09.png
21 changes: 21 additions & 0 deletions tools/sas/remove-low-coordinated.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
f = open("cn.dat", "r")
lines = f.readlines()
f.close()

f = open("out.xyz", "r")
coords = f.readlines()
f.close()

new_coords = []

for i in range(len(lines)):
nc = int(lines[i])
if nc > 5:
new_coords.append(coords[2+i])

o = open("out.new.xyz", "w")
o.write("%d\n\n"%len(new_coords))
for i in new_coords:
o.write(i)
o.close()

0 comments on commit 8281dc5

Please sign in to comment.