예제 #1
0
    def create(filename, hdr=None, anatFile=None):
        f = open(filename, 'wb')
        f.write(FIB.MAGIC_NUMBER + "\n")
        f.close()

        if hdr is None:
            hdr = VTK.get_empty_header()
        else:
            hdr = copy.deepcopy(hdr)

        fib = FIB(filename, load=False)
        fib.hdr = hdr
        fib.writeHeader()

        return fib
예제 #2
0
    def _check(filename):
        if VTK._check(filename):
            return False

        return filename[-3:].lower() == FIB.MAGIC_NUMBER
예제 #3
0
    def _check(filename):
        if VTK._check(filename):
            return False

        return filename[-3:].lower() == FIB.MAGIC_NUMBER