def load(filename, *, gzipped=None, byteorder='<STR_LIT>'):
if gzipped is not None:<EOL><INDENT>return File.load(filename, gzipped, byteorder)<EOL><DEDENT>with open(filename, '<STR_LIT:rb>') as buff:<EOL><INDENT>magic_number = buff.read(<NUM_LIT:2>)<EOL>buff.seek(<NUM_LIT:0>)<EOL>if magic_number == b'<STR_LIT>':<EOL><INDENT>buff = gzip.GzipFile(fileobj=buff)<EOL><DEDENT>return File.from_buffer(buff, byteorder)<EOL><DEDENT>
Load the nbt file at the specified location.

    By default, the function will figure out by itself if the file is
    gzipped before loading it. You can pass a boolean to the `gzipped`
    keyword only argument to specify explicitly whether the file is
    compressed or not. You can also use the `byteorder` keyword only
    argument to specify whether the file is little-endian or big-endian.