Dear Radiance Users,
I've assembled a simple script that iterates through a folder containing
octrees, and renders using SMP. On Mac, everything works as expected.
However, on Linux, I get errors suggesting both the syncfile and ppfile
are still locked by the OS. I've attempted two solutions, including
adding 'sleep 5' after pfilt (first attempt, shown below), and then by
externalizing the while loop, with an ending 'exit 0' (second attempt,
not shown here), but neither approach fixed the problem.
Here is one version of code which works on Mac but not in Linux:
for file in obj/*.oct
do
filename="${file%.*}"
rm -f syncfile argsfile ppfile
echo 1 64 > syncfile
cat syncfile
echo -F syncfile @arguments -vf room.vf -o $filename.unf
$filename.oct > argsfile
cat argsfile
NCPU=2
while [ "$NCPU" -gt 0 ]
do
echo "running proc $NCPU"
rpiece -v -PP ppfile @argsfile &
sleep 5
NCPU=`expr $NCPU - 1`
done
wait
echo "Filtering File - $filename.unf"
pfilt -1 -e -2 -m .25 -r .6 -x /3 -y /3 $filename.unf > $filename.hdr
sleep 5
rm -f syncfile argsfile ppfile
done
Interestingly, I do not get an error saying "cannot remove 'argsfile' ".
After the first image is successfully rendered, I get the following
errors at each successive iteration, indicating the rm only works once
(line 4) in the first iteration:
rm: cannot remove 'syncfile': Text file busy
rm: cannot remove 'ppfile': Text file busy
rm: cannot remove 'syncfile': Text file busy
rm: cannot remove 'ppfile': Text file busy
Since the error isn't fatal, the machine keeps rendering, and ends up
rendering the same (first) image over and over. Has anyone run into this
problem and found a solution? Any advice would be greatly appreciated.
Thanks,
Chris
_______________________________________________
HDRI mailing list
[email protected]
http://www.radiance-online.org/mailman/listinfo/hdri