1 instantiation of Header
Microsoft.ML.Data (1)
DataLoadSave\Binary\BinarySaver.cs (1)
544Header header = new Header()
40 references to Header
Microsoft.ML.Data (40)
DataLoadSave\Binary\BinaryLoader.cs (29)
150_ectx.Assert(metadataTocOffset == 0 || Header.HeaderSize <= metadataTocOffset); 152_ectx.Assert(Header.HeaderSize <= lookupOffset); 261_ectx.CheckDecode(Header.HeaderSize <= offset && offset <= _parent._header.TailOffset - compLen, "block offset out of range"); 346ch.CheckDecode(Header.HeaderSize <= blockOffset && blockOffset <= _parent._header.TailOffset, 486Contracts.Assert(Header.HeaderSize <= blockOffset); 674private readonly Header _header; 1029private unsafe Header InitHeader() 1031byte[] headerBytes = new byte[Header.HeaderSize]; 1032int cb = _reader.Read(headerBytes, 0, Header.HeaderSize); 1033if (cb != Header.HeaderSize) 1036cb, Header.HeaderSize); 1038Header header; 1041Marshal.Copy(headerBytes, 0, (IntPtr)(&header), Header.HeaderSize); 1047_host.CheckDecode(header.Signature == Header.SignatureValue, 1054Header.VersionToString(header.CompatibleVersion), Header.VersionToString(header.Version)); 1060Header.VersionToString(header.Version), Header.VersionToString(ReaderFirstVersion)); 1069Header.VersionToString(header.CompatibleVersion), Header.VersionToString(MetadataVersion)); 1074Header.VersionToString(header.CompatibleVersion), Header.VersionToString(ReaderVersion)); 1080if (header.ColumnCount != 0 && header.TableOfContentsOffset < Header.HeaderSize) 1084if (header.TailOffset < Header.HeaderSize) 1088_host.CheckDecode(tailSig == Header.TailSignatureValue, "Incorrect tail signature"); 1129ch.CheckDecode(Header.HeaderSize <= lookupOffset && lookupOffset <= _header.TailOffset - 16 * lookupLen, 1133ch.CheckDecode(metadataTocOffset == 0 || Header.HeaderSize <= metadataTocOffset && metadataTocOffset <= _header.TailOffset, 2151Header header = loader._header; 2226const long headTailSize = Header.HeaderSize + sizeof(ulong);
DataLoadSave\Binary\BinarySaver.cs (10)
419stream.Write(new byte[Header.HeaderSize], 0, Header.HeaderSize); 420ch.CheckIO(stream.Position == Header.HeaderSize); 541writer.Write(Header.TailSignatureValue); 544Header header = new Header() 546Signature = Header.SignatureValue, 547Version = Header.WriterVersion, 548CompatibleVersion = Header.CanBeReadByVersion, 554byte[] headerBytes = new byte[Header.HeaderSize]; 557Marshal.Copy(new IntPtr(&header), headerBytes, 0, Marshal.SizeOf(typeof(Header)));
DataLoadSave\Transpose\TransposeSaver.cs (1)
179Marshal.Copy(new IntPtr(&header), headerBytes, 0, Marshal.SizeOf(typeof(Header)));