def __setattr__(self, name: str, val: np.ndarray) -> None:
if name.startswith("<STR_LIT:!>"):<EOL><INDENT>super(AttributeManager, self).__setattr__(name[<NUM_LIT:1>:], val)<EOL><DEDENT>elif "<STR_LIT:/>" in name:<EOL><INDENT>raise KeyError("<STR_LIT>")<EOL><DEDENT>else:<EOL><INDENT>if self.ds is not None:<EOL><INDENT>values = loompy.normalize_attr_values(val)<EOL>a = ["<STR_LIT>", "<STR_LIT>"][self.axis]<EOL>if self.ds.shape[self.axis] != <NUM_LIT:0> and values.shape[<NUM_LIT:0>] != self.ds.shape[self.axis]:<EOL><INDENT>raise ValueError(f"<STR_LIT>")<EOL><DEDENT>if self.ds._file[a].__contains__(name):<EOL><INDENT>del self.ds._file[a + name]<EOL><DEDENT>self.ds._file[a + name] = values  <EOL>self.ds._file[a + name].attrs["<STR_LIT>"] = timestamp()<EOL>self.ds._file[a].attrs["<STR_LIT>"] = timestamp()<EOL>self.ds._file.attrs["<STR_LIT>"] = timestamp()<EOL>self.ds._file.flush()<EOL>self.__dict__["<STR_LIT>"][name] = loompy.materialize_attr_values(self.ds._file[a][name][:])<EOL><DEDENT>else:<EOL><INDENT>self.__dict__["<STR_LIT>"][name] = val<EOL><DEDENT><DEDENT>
Set the value of a named attribute

Args:
        name (str) 			Name of the attribute
        val (np.ndarray)	Value of the attribute

Remarks:
        Length must match the corresponding matrix dimension
        The values are automatically HMTL escaped and converted to ASCII for storage