Ejemplo n.º 1
0
        static void WriteFile(string filePath)
        {
            var file = Hdf5.CreateFile(filePath);

            var group = Hdf5.CreateOrOpenGroup(file, "group");

            Hdf5.WriteDataset(group, "dataset",
                              new int[, ]
            {
                { 1, 2, 3, 4 },
                { 5, 6, 7, 8 },
                { 9, 10, 11, 12 }
            });

            var hello = "早上好!";

            Hdf5.WriteStringAttribute(group, "string", hello, "dataset");

            Hdf5.CloseGroup(group);
            Hdf5.CloseFile(file);
        }