{ "version": 3, "sources": ["index.js", "lib/table/simple-table/data-type.js", "lib/table/batches/base-table-batch-aggregator.js", "lib/table/simple-table/row-utils.js", "lib/table/batches/row-table-batch-aggregator.js", "lib/table/batches/columnar-table-batch-aggregator.js", "lib/table/batches/table-batch-builder.js", "lib/table/simple-table/table-accessors.js", "lib/table/arrow-api/arrow-like-field.js", "lib/table/arrow-api/arrow-like-schema.js", "lib/table/simple-table/table-schema.js", "lib/table/arrow-api/arrow-like-table.js", "lib/table/simple-table/make-table.js", "lib/table/simple-table/make-table-from-batches.js", "lib/table/simple-table/table-column.js", "lib/table/simple-table/convert-table.js", "lib/mesh/mesh-utils.js", "lib/mesh/deduce-mesh-schema.js", "lib/table/arrow-api/enum.js", "lib/table/arrow-api/arrow-like-type.js", "lib/table/arrow-api/get-type-info.js", "lib/utils/async-queue.js"], "sourcesContent": ["// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nexport { getArrayTypeFromDataType } from \"./lib/table/simple-table/data-type.js\";\n// TABLE CATEGORY UTILS\nexport { TableBatchBuilder } from \"./lib/table/batches/table-batch-builder.js\";\nexport { RowTableBatchAggregator } from \"./lib/table/batches/row-table-batch-aggregator.js\";\nexport { ColumnarTableBatchAggregator } from \"./lib/table/batches/columnar-table-batch-aggregator.js\";\nexport { isTable, getTableLength, getTableNumCols, getTableCell, getTableCellAt, getTableRowShape, getTableColumnIndex, getTableColumnName, getTableRowAsObject, getTableRowAsArray, makeRowIterator, makeArrayRowIterator, makeObjectRowIterator } from \"./lib/table/simple-table/table-accessors.js\";\nexport { ArrowLikeTable } from \"./lib/table/arrow-api/arrow-like-table.js\";\nexport { makeTableFromData } from \"./lib/table/simple-table/make-table.js\";\nexport { makeTableFromBatches, makeBatchFromTable } from \"./lib/table/simple-table/make-table-from-batches.js\";\nexport { convertTable } from \"./lib/table/simple-table/convert-table.js\";\nexport { deduceTableSchema } from \"./lib/table/simple-table/table-schema.js\";\nexport { convertToObjectRow, convertToArrayRow } from \"./lib/table/simple-table/row-utils.js\";\nexport { getDataTypeFromArray } from \"./lib/table/simple-table/data-type.js\";\nexport { getMeshSize, getMeshBoundingBox } from \"./lib/mesh/mesh-utils.js\";\n// Commented out due to https://github.com/visgl/deck.gl/issues/6906 and https://github.com/visgl/loaders.gl/issues/2177\n// export {convertMesh} from './category/mesh/convert-mesh';\nexport { deduceMeshSchema, deduceMeshField, makeMeshAttributeMetadata } from \"./lib/mesh/deduce-mesh-schema.js\";\n// SCHEMA\nexport { Schema as ArrowLikeSchema, Field as ArrowLikeField, DataType as ArrowLikeDataType, Null, Binary, Bool, Int, Int8, Int16, Int32, Int64, Uint8, Uint16, Uint32, Uint64, Float, Float16, Float32, Float64, Utf8, Date, DateDay, DateMillisecond, Time, TimeMillisecond, TimeSecond, Timestamp, TimestampSecond, TimestampMillisecond, TimestampMicrosecond, TimestampNanosecond, Interval, IntervalDayTime, IntervalYearMonth, FixedSizeList, Struct } from \"./lib/table/arrow-api/index.js\";\n// EXPERIMENTAL APIs\n// SCHEMA UTILS\nexport { getTypeInfo } from \"./lib/table/arrow-api/get-type-info.js\";\nexport { default as AsyncQueue } from \"./lib/utils/async-queue.js\";\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\n/** Deduce column types from values */\nexport function getDataTypeFromValue(value, defaultNumberType = 'float32') {\n if (value instanceof Date) {\n return 'date-millisecond';\n }\n if (value instanceof Number) {\n return defaultNumberType;\n }\n if (typeof value === 'string') {\n return 'utf8';\n }\n if (value === null || value === 'undefined') {\n return 'null';\n }\n return 'null';\n}\n/**\n * Deduces a simple data type \"descriptor from a typed array instance\n */\nexport function getDataTypeFromArray(array) {\n let type = getDataTypeFromTypedArray(array);\n if (type !== 'null') {\n return { type, nullable: false };\n }\n if (array.length > 0) {\n type = getDataTypeFromValue(array[0]);\n return { type, nullable: true };\n }\n return { type: 'null', nullable: true };\n}\n/**\n * Deduces a simple data type \"descriptor from a typed array instance\n */\nexport function getDataTypeFromTypedArray(array) {\n switch (array.constructor) {\n case Int8Array:\n return 'int8';\n case Uint8Array:\n case Uint8ClampedArray:\n return 'uint8';\n case Int16Array:\n return 'int16';\n case Uint16Array:\n return 'uint16';\n case Int32Array:\n return 'int32';\n case Uint32Array:\n return 'uint32';\n case Float32Array:\n return 'float32';\n case Float64Array:\n return 'float64';\n default:\n return 'null';\n }\n}\nexport function getArrayTypeFromDataType(type, nullable) {\n if (!nullable) {\n switch (type) {\n case 'int8':\n return Int8Array;\n case 'uint8':\n return Uint8Array;\n case 'int16':\n return Int16Array;\n case 'uint16':\n return Uint16Array;\n case 'int32':\n return Int32Array;\n case 'uint32':\n return Uint32Array;\n case 'float32':\n return Float32Array;\n case 'float64':\n return Float64Array;\n default:\n break;\n }\n }\n // if (typeof BigInt64Array !== 'undefined') {\n // TYPED_ARRAY_TO_TYPE.BigInt64Array = new Int64();\n // TYPED_ARRAY_TO_TYPE.BigUint64Array = new Uint64();\n // }\n return Array;\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nconst DEFAULT_ROW_COUNT = 100;\nexport class BaseTableBatchAggregator {\n schema;\n options;\n shape;\n length = 0;\n rows = null;\n cursor = 0;\n _headers = [];\n constructor(schema, options) {\n this.options = options;\n this.schema = schema;\n // schema is an array if there're no headers\n // object if there are headers\n if (!Array.isArray(schema)) {\n this._headers = [];\n for (const key in schema) {\n this._headers[schema[key].index] = schema[key].name;\n }\n }\n }\n rowCount() {\n return this.length;\n }\n addArrayRow(row, cursor) {\n if (Number.isFinite(cursor)) {\n this.cursor = cursor;\n }\n this.shape = 'array-row-table';\n this.rows = this.rows || new Array(DEFAULT_ROW_COUNT);\n this.rows[this.length] = row;\n this.length++;\n }\n addObjectRow(row, cursor) {\n if (Number.isFinite(cursor)) {\n this.cursor = cursor;\n }\n this.shape = 'object-row-table';\n this.rows = this.rows || new Array(DEFAULT_ROW_COUNT);\n this.rows[this.length] = row;\n this.length++;\n }\n getBatch() {\n let rows = this.rows;\n if (!rows) {\n return null;\n }\n rows = rows.slice(0, this.length);\n this.rows = null;\n const batch = {\n shape: this.shape || 'array-row-table',\n batchType: 'data',\n data: rows,\n length: this.length,\n schema: this.schema,\n cursor: this.cursor\n };\n return batch;\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\n/** Convert an object row to an array row */\nexport function convertToObjectRow(arrayRow, headers) {\n if (!arrayRow) {\n throw new Error('null row');\n }\n const objectRow = {};\n if (headers) {\n for (let i = 0; i < headers.length; i++) {\n objectRow[headers[i]] = arrayRow[i];\n }\n }\n else {\n for (let i = 0; i < arrayRow.length; i++) {\n const columnName = `column-${i}`;\n objectRow[columnName] = arrayRow[i];\n }\n }\n return objectRow;\n}\n/** Convert an object row to an array row */\nexport function convertToArrayRow(objectRow, headers) {\n if (!objectRow) {\n throw new Error('null row');\n }\n if (headers) {\n const arrayRow = new Array(headers.length);\n for (let i = 0; i < headers.length; i++) {\n arrayRow[i] = objectRow[headers[i]];\n }\n return arrayRow;\n }\n return Object.values(objectRow);\n}\n/** Get headers from a sample array row */\nexport function inferHeadersFromArrayRow(arrayRow) {\n const headers = [];\n for (let i = 0; i < arrayRow.length; i++) {\n const columnName = `column-${i}`;\n headers.push(columnName);\n }\n return headers;\n}\n/** Get headers from a smaple object row */\nexport function inferHeadersFromObjectRow(row) {\n return Object.keys(row);\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { convertToArrayRow, convertToObjectRow, inferHeadersFromArrayRow, inferHeadersFromObjectRow } from \"../simple-table/row-utils.js\";\nconst DEFAULT_ROW_COUNT = 100;\nexport class RowTableBatchAggregator {\n schema;\n options;\n length = 0;\n objectRows = null;\n arrayRows = null;\n cursor = 0;\n _headers = null;\n constructor(schema, options) {\n this.options = options;\n this.schema = schema;\n // schema is an array if there're no headers\n // object if there are headers\n if (schema) {\n this._headers = [];\n for (const key in schema) {\n this._headers[schema[key].index] = schema[key].name;\n }\n }\n }\n rowCount() {\n return this.length;\n }\n addArrayRow(row, cursor) {\n if (Number.isFinite(cursor)) {\n this.cursor = cursor;\n }\n // TODO - infer schema at a higher level, instead of hacking headers here?\n this._headers ||= inferHeadersFromArrayRow(row);\n // eslint-disable-next-line default-case\n switch (this.options.shape) {\n case 'object-row-table':\n const rowObject = convertToObjectRow(row, this._headers);\n this.addObjectRow(rowObject, cursor);\n break;\n case 'array-row-table':\n this.arrayRows = this.arrayRows || new Array(DEFAULT_ROW_COUNT);\n this.arrayRows[this.length] = row;\n this.length++;\n break;\n }\n }\n addObjectRow(row, cursor) {\n if (Number.isFinite(cursor)) {\n this.cursor = cursor;\n }\n // TODO - infer schema at a higher level, instead of hacking headers here?\n this._headers ||= inferHeadersFromObjectRow(row);\n // eslint-disable-next-line default-case\n switch (this.options.shape) {\n case 'array-row-table':\n const rowArray = convertToArrayRow(row, this._headers);\n this.addArrayRow(rowArray, cursor);\n break;\n case 'object-row-table':\n this.objectRows = this.objectRows || new Array(DEFAULT_ROW_COUNT);\n this.objectRows[this.length] = row;\n this.length++;\n break;\n }\n }\n getBatch() {\n let rows = this.arrayRows || this.objectRows;\n if (!rows) {\n return null;\n }\n rows = rows.slice(0, this.length);\n this.arrayRows = null;\n this.objectRows = null;\n return {\n shape: this.options.shape,\n batchType: 'data',\n data: rows,\n length: this.length,\n // @ts-expect-error we should infer a schema\n schema: this.schema,\n cursor: this.cursor\n };\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nconst DEFAULT_ROW_COUNT = 100;\nexport class ColumnarTableBatchAggregator {\n schema;\n length = 0;\n allocated = 0;\n columns = {};\n constructor(schema, options) {\n this.schema = schema;\n this._reallocateColumns();\n }\n rowCount() {\n return this.length;\n }\n addArrayRow(row) {\n // If user keeps pushing rows beyond batch size, reallocate\n this._reallocateColumns();\n let i = 0;\n // TODO what if no csv header, columns not populated?\n for (const fieldName in this.columns) {\n this.columns[fieldName][this.length] = row[i++];\n }\n this.length++;\n }\n addObjectRow(row) {\n // If user keeps pushing rows beyond batch size, reallocate\n this._reallocateColumns();\n for (const fieldName in row) {\n this.columns[fieldName][this.length] = row[fieldName];\n }\n this.length++;\n }\n getBatch() {\n this._pruneColumns();\n const columns = Array.isArray(this.schema) ? this.columns : {};\n // schema is an array if there're no headers\n // object if there are headers\n // columns should match schema format\n if (!Array.isArray(this.schema)) {\n for (const fieldName in this.schema) {\n const field = this.schema[fieldName];\n columns[field.name] = this.columns[field.index];\n }\n }\n this.columns = {};\n const batch = {\n shape: 'columnar-table',\n batchType: 'data',\n data: columns,\n schema: this.schema,\n length: this.length\n };\n return batch;\n }\n // HELPERS\n _reallocateColumns() {\n if (this.length < this.allocated) {\n return;\n }\n // @ts-ignore TODO\n this.allocated = this.allocated > 0 ? (this.allocated *= 2) : DEFAULT_ROW_COUNT;\n this.columns = {};\n for (const fieldName in this.schema) {\n const field = this.schema[fieldName];\n const ArrayType = field.type || Float32Array;\n const oldColumn = this.columns[field.index];\n if (oldColumn && ArrayBuffer.isView(oldColumn)) {\n // Copy the old data to the new array\n const typedArray = new ArrayType(this.allocated);\n typedArray.set(oldColumn);\n this.columns[field.index] = typedArray;\n }\n else if (oldColumn) {\n // Plain array\n oldColumn.length = this.allocated;\n this.columns[field.index] = oldColumn;\n }\n else {\n // Create new\n this.columns[field.index] = new ArrayType(this.allocated);\n }\n }\n }\n _pruneColumns() {\n for (const [columnName, column] of Object.entries(this.columns)) {\n this.columns[columnName] = column.slice(0, this.length);\n }\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { BaseTableBatchAggregator } from \"./base-table-batch-aggregator.js\";\nimport { RowTableBatchAggregator } from \"./row-table-batch-aggregator.js\";\nimport { ColumnarTableBatchAggregator } from \"./columnar-table-batch-aggregator.js\";\nconst DEFAULT_OPTIONS = {\n shape: undefined,\n batchSize: 'auto',\n batchDebounceMs: 0,\n limit: 0,\n _limitMB: 0\n};\nconst ERR_MESSAGE = 'TableBatchBuilder';\n/** Incrementally builds batches from a stream of rows */\nexport class TableBatchBuilder {\n schema;\n options;\n aggregator = null;\n batchCount = 0;\n bytesUsed = 0;\n isChunkComplete = false;\n lastBatchEmittedMs = Date.now();\n totalLength = 0;\n totalBytes = 0;\n rowBytes = 0;\n static ArrowBatch;\n constructor(schema, options) {\n this.schema = schema;\n this.options = { ...DEFAULT_OPTIONS, ...options };\n }\n limitReached() {\n if (Boolean(this.options?.limit) && this.totalLength >= this.options.limit) {\n return true;\n }\n if (Boolean(this.options?._limitMB) && this.totalBytes / 1e6 >= this.options._limitMB) {\n return true;\n }\n return false;\n }\n /** @deprecated Use addArrayRow or addObjectRow */\n addRow(row) {\n if (this.limitReached()) {\n return;\n }\n this.totalLength++;\n this.rowBytes = this.rowBytes || this._estimateRowMB(row);\n this.totalBytes += this.rowBytes;\n if (Array.isArray(row)) {\n this.addArrayRow(row);\n }\n else {\n this.addObjectRow(row);\n }\n }\n /** Add one row to the batch */\n addArrayRow(row) {\n if (!this.aggregator) {\n const TableBatchType = this._getTableBatchType();\n this.aggregator = new TableBatchType(this.schema, this.options);\n }\n this.aggregator.addArrayRow(row);\n }\n /** Add one row to the batch */\n addObjectRow(row) {\n if (!this.aggregator) {\n const TableBatchType = this._getTableBatchType();\n this.aggregator = new TableBatchType(this.schema, this.options);\n }\n this.aggregator.addObjectRow(row);\n }\n /** Mark an incoming raw memory chunk has completed */\n chunkComplete(chunk) {\n if (chunk instanceof ArrayBuffer) {\n this.bytesUsed += chunk.byteLength;\n }\n if (typeof chunk === 'string') {\n this.bytesUsed += chunk.length;\n }\n this.isChunkComplete = true;\n }\n getFullBatch(options) {\n return this._isFull() ? this._getBatch(options) : null;\n }\n getFinalBatch(options) {\n return this._getBatch(options);\n }\n // INTERNAL\n _estimateRowMB(row) {\n return Array.isArray(row) ? row.length * 8 : Object.keys(row).length * 8;\n }\n _isFull() {\n // No batch, not ready\n if (!this.aggregator || this.aggregator.rowCount() === 0) {\n return false;\n }\n // if batchSize === 'auto' we wait for chunk to complete\n // if batchSize === number, ensure we have enough rows\n if (this.options.batchSize === 'auto') {\n if (!this.isChunkComplete) {\n return false;\n }\n }\n else if (this.options.batchSize > this.aggregator.rowCount()) {\n return false;\n }\n // Debounce batches\n if (this.options.batchDebounceMs > Date.now() - this.lastBatchEmittedMs) {\n return false;\n }\n // Emit batch\n this.isChunkComplete = false;\n this.lastBatchEmittedMs = Date.now();\n return true;\n }\n /**\n * bytesUsed can be set via chunkComplete or via getBatch*\n */\n _getBatch(options) {\n if (!this.aggregator) {\n return null;\n }\n // TODO - this can overly increment bytes used?\n if (options?.bytesUsed) {\n this.bytesUsed = options.bytesUsed;\n }\n const normalizedBatch = this.aggregator.getBatch();\n normalizedBatch.count = this.batchCount;\n normalizedBatch.bytesUsed = this.bytesUsed;\n Object.assign(normalizedBatch, options);\n this.batchCount++;\n this.aggregator = null;\n return normalizedBatch;\n }\n _getTableBatchType() {\n switch (this.options.shape) {\n case 'array-row-table':\n case 'object-row-table':\n return RowTableBatchAggregator;\n case 'columnar-table':\n return ColumnarTableBatchAggregator;\n case 'arrow-table':\n if (!TableBatchBuilder.ArrowBatch) {\n throw new Error(ERR_MESSAGE);\n }\n return TableBatchBuilder.ArrowBatch;\n default:\n return BaseTableBatchAggregator;\n }\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nexport function isTable(table) {\n const shape = typeof table === 'object' && table?.shape;\n switch (shape) {\n case 'array-row-table':\n case 'object-row-table':\n return Array.isArray(table.data);\n case 'geojson-table':\n return Array.isArray(table.features);\n case 'columnar-table':\n return table.data && typeof table.data === 'object';\n case 'arrow-table':\n return Boolean(table?.data?.numRows !== undefined);\n default:\n return false;\n }\n}\n/**\n * Returns the length of the table (i.e. the number of rows)\n */\nexport function getTableLength(table) {\n switch (table.shape) {\n case 'array-row-table':\n case 'object-row-table':\n return table.data.length;\n case 'geojson-table':\n return table.features.length;\n case 'arrow-table':\n const arrowTable = table.data;\n return arrowTable.numRows;\n case 'columnar-table':\n for (const column of Object.values(table.data)) {\n return column.length || 0;\n }\n return 0;\n default:\n throw new Error('table');\n }\n}\n/**\n * Returns the number of columns in the table\n * @throws Fails to deduce number of columns if the table has no schema and is empty\n */\nexport function getTableNumCols(table) {\n if (table.schema) {\n return table.schema.fields.length;\n }\n if (getTableLength(table) === 0) {\n throw new Error('empty table');\n }\n switch (table.shape) {\n case 'array-row-table':\n return table.data[0].length;\n case 'object-row-table':\n return Object.keys(table.data[0]).length;\n case 'geojson-table':\n return Object.keys(table.features[0]).length;\n case 'columnar-table':\n return Object.keys(table.data).length;\n case 'arrow-table':\n const arrowTable = table.data;\n return arrowTable.numCols;\n default:\n throw new Error('table');\n }\n}\n/** Get a table cell value at row index and column name */\nexport function getTableCell(table, rowIndex, columnName) {\n switch (table.shape) {\n case 'array-row-table':\n const columnIndex = getTableColumnIndex(table, columnName);\n return table.data[rowIndex][columnIndex];\n case 'object-row-table':\n return table.data[rowIndex][columnName];\n case 'geojson-table':\n return table.features[rowIndex][columnName];\n case 'columnar-table':\n const column = table.data[columnName];\n return column[rowIndex];\n case 'arrow-table':\n const arrowTable = table.data;\n const arrowColumnIndex = arrowTable.schema.fields.findIndex((field) => field.name === columnName);\n return arrowTable.getChildAt(arrowColumnIndex)?.get(rowIndex);\n default:\n throw new Error('todo');\n }\n}\n/** Get a table cell value at row index and column name */\nexport function getTableCellAt(table, rowIndex, columnIndex) {\n switch (table.shape) {\n case 'array-row-table':\n return table.data[rowIndex][columnIndex];\n case 'object-row-table':\n const columnName1 = getTableColumnName(table, columnIndex);\n return table.data[rowIndex][columnName1];\n case 'geojson-table':\n const columnName2 = getTableColumnName(table, columnIndex);\n return table.features[rowIndex][columnName2];\n case 'columnar-table':\n const columnName3 = getTableColumnName(table, columnIndex);\n const column = table.data[columnName3];\n return column[rowIndex];\n case 'arrow-table':\n const arrowTable = table.data;\n return arrowTable.getChildAt(columnIndex)?.get(rowIndex);\n default:\n throw new Error('todo');\n }\n}\n/** Deduce the table row shape */\nexport function getTableRowShape(table) {\n switch (table.shape) {\n case 'array-row-table':\n case 'object-row-table':\n return table.shape;\n case 'geojson-table':\n // TODO - this is not correct, geojson-table is not a row table\n return 'object-row-table';\n case 'columnar-table':\n default:\n throw new Error('Not a row table');\n }\n}\n/** Get the index of a named table column. Requires the table to have a schema */\nexport function getTableColumnIndex(table, columnName) {\n const columnIndex = table.schema?.fields.findIndex((field) => field.name === columnName);\n if (columnIndex === undefined) {\n throw new Error(columnName);\n }\n return columnIndex;\n}\n/** Get the name of a table column by index. Requires the table to have a schema */\nexport function getTableColumnName(table, columnIndex) {\n const columnName = table.schema?.fields[columnIndex]?.name;\n if (!columnName) {\n throw new Error(`${columnIndex}`);\n }\n return columnName;\n}\n/**\n * Returns one row of the table in object format.\n * @param target Optional parameter will be used if needed to store the row. Can be reused between calls to improve performance\n * @returns an array representing the row. May be the original array in the row, a new object, or the target parameter\n */\n// eslint-disable-next-line complexity\nexport function getTableRowAsObject(table, rowIndex, target, copy) {\n switch (table.shape) {\n case 'object-row-table':\n return copy ? Object.fromEntries(Object.entries(table.data[rowIndex])) : table.data[rowIndex];\n case 'array-row-table':\n if (table.schema) {\n const objectRow = target || {};\n for (let i = 0; i < table.schema.fields.length; i++) {\n objectRow[table.schema.fields[i].name] = table.data[rowIndex][i];\n }\n return objectRow;\n }\n throw new Error('no schema');\n case 'geojson-table':\n if (table.schema) {\n const objectRow = target || {};\n // TODO - should lift properties to top level\n for (let i = 0; i < table.schema.fields.length; i++) {\n objectRow[table.schema.fields[i].name] = table.features[rowIndex][i];\n }\n return objectRow;\n }\n throw new Error('no schema');\n case 'columnar-table':\n if (table.schema) {\n const objectRow = target || {};\n for (let i = 0; i < table.schema.fields.length; i++) {\n objectRow[table.schema.fields[i].name] =\n table.data[table.schema.fields[i].name][rowIndex];\n }\n return objectRow;\n }\n else {\n // eslint-disable-line no-else-return\n const objectRow = target || {};\n for (const [name, column] of Object.entries(table.data)) {\n objectRow[name] = column[rowIndex];\n }\n return objectRow;\n }\n case 'arrow-table':\n const arrowTable = table.data;\n const objectRow = target || {};\n const row = arrowTable.get(rowIndex);\n const schema = arrowTable.schema;\n for (let i = 0; i < schema.fields.length; i++) {\n objectRow[schema.fields[i].name] = row?.[schema.fields[i].name];\n }\n return objectRow;\n default:\n throw new Error('shape');\n }\n}\n/**\n * Returns one row of the table in array format.\n * @param target Optional parameter will be used if needed to store the row. Can be reused between calls to improve performance.\n * @returns an array representing the row. May be the original array in the row, a new object, or the target parameter\n */\n// eslint-disable-next-line complexity\nexport function getTableRowAsArray(table, rowIndex, target, copy) {\n switch (table.shape) {\n case 'array-row-table':\n return copy ? Array.from(table.data[rowIndex]) : table.data[rowIndex];\n case 'object-row-table':\n if (table.schema) {\n const arrayRow = target || [];\n for (let i = 0; i < table.schema.fields.length; i++) {\n arrayRow[i] = table.data[rowIndex][table.schema.fields[i].name];\n }\n return arrayRow;\n }\n // Warning: just slap on the values, this risks mismatches between rows\n return Object.values(table.data[rowIndex]);\n case 'geojson-table':\n if (table.schema) {\n const arrayRow = target || [];\n // TODO - should lift properties to top level\n for (let i = 0; i < table.schema.fields.length; i++) {\n arrayRow[i] = table.features[rowIndex][table.schema.fields[i].name];\n }\n return arrayRow;\n }\n // Warning: just slap on the values, this risks mismatches between rows\n return Object.values(table.features[rowIndex]);\n case 'columnar-table':\n if (table.schema) {\n const arrayRow = target || [];\n for (let i = 0; i < table.schema.fields.length; i++) {\n arrayRow[i] = table.data[table.schema.fields[i].name][rowIndex];\n }\n return arrayRow;\n }\n else {\n // eslint-disable-line no-else-return\n const arrayRow = target || [];\n let i = 0;\n for (const column of Object.values(table.data)) {\n arrayRow[i] = column[rowIndex];\n i++;\n }\n return arrayRow;\n }\n case 'arrow-table':\n const arrowTable = table.data;\n const arrayRow = target || [];\n const row = arrowTable.get(rowIndex);\n const schema = arrowTable.schema;\n for (let i = 0; i < schema.fields.length; i++) {\n arrayRow[i] = row?.[schema.fields[i].name];\n }\n return arrayRow;\n default:\n throw new Error('shape');\n }\n}\n/** Convert any table into array row format */\nexport function makeArrayRowTable(table) {\n if (table.shape === 'array-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsArray(table, rowIndex);\n }\n return {\n shape: 'array-row-table',\n schema: table.schema,\n data\n };\n}\n/** Convert any table into object row format */\nexport function makeObjectRowTable(table) {\n if (table.shape === 'object-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsObject(table, rowIndex);\n }\n return {\n shape: 'object-row-table',\n schema: table.schema,\n data\n };\n}\n/** Convert any table into object row format */\nexport function makeColumnarTable(table) {\n if (table.shape === 'object-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsObject(table, rowIndex);\n }\n return {\n shape: 'object-row-table',\n schema: table.schema,\n data\n };\n}\n// Row Iterators\n/**\n * Iterate over table rows\n * @param table\n * @param shape\n */\nexport function* makeRowIterator(table, shape) {\n switch (shape) {\n case 'array-row-table':\n yield* makeArrayRowIterator(table);\n break;\n case 'object-row-table':\n yield* makeObjectRowIterator(table);\n break;\n default:\n throw new Error(`Unknown row type ${shape}`);\n }\n}\n/**\n * Streaming processing: Iterate over table, yielding array rows\n * @param table\n * @param shape\n */\nexport function* makeArrayRowIterator(table, target = []) {\n const length = getTableLength(table);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n yield getTableRowAsArray(table, rowIndex, target);\n }\n}\n/**\n * Streaming processing: Iterate over table, yielding object rows\n * @param table\n * @param shape\n */\nexport function* makeObjectRowIterator(table, target = {}) {\n const length = getTableLength(table);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n yield getTableRowAsObject(table, rowIndex, target);\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\n/**\n * ArrowJS `Field` API-compatible class for row-based tables\n * https://loaders.gl/arrowjs/docs/api-reference/field\n * A field holds name, nullable, and metadata information about a table \"column\"\n * A Schema is essentially a list of fields\n */\nexport class ArrowLikeField {\n name;\n type;\n nullable;\n metadata;\n constructor(name, type, nullable = false, metadata = new Map()) {\n this.name = name;\n this.type = type;\n this.nullable = nullable;\n this.metadata = metadata;\n }\n get typeId() {\n return this.type && this.type.typeId;\n }\n clone() {\n return new ArrowLikeField(this.name, this.type, this.nullable, this.metadata);\n }\n compareTo(other) {\n return (this.name === other.name &&\n this.type === other.type &&\n this.nullable === other.nullable &&\n this.metadata === other.metadata);\n }\n toString() {\n return `${JSON.stringify(this.type)}${this.nullable ? ', nullable' : ''}${this.metadata ? `, metadata: ${JSON.stringify(this.metadata)}` : ''}`;\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { ArrowLikeField } from \"./arrow-like-field.js\";\nexport class ArrowLikeSchema {\n fields;\n metadata;\n constructor(fields, metadata = new Map()) {\n // checkNames(fields);\n // For kepler fields, create arrow compatible `Fields` that have kepler fields as `metadata`\n this.fields = fields.map((field) => new ArrowLikeField(field.name, field.type, field.nullable, field.metadata));\n this.metadata =\n metadata instanceof Map ? metadata : new Map(Object.entries(metadata));\n }\n // TODO - arrow only seems to compare fields, not metadata\n compareTo(other) {\n if (this.metadata !== other.metadata) {\n return false;\n }\n if (this.fields.length !== other.fields.length) {\n return false;\n }\n for (let i = 0; i < this.fields.length; ++i) {\n if (!this.fields[i].compareTo(other.fields[i])) {\n return false;\n }\n }\n return true;\n }\n select(...columnNames) {\n // Ensure column names reference valid fields\n const nameMap = Object.create(null);\n for (const name of columnNames) {\n nameMap[name] = true;\n }\n const selectedFields = this.fields.filter((field) => nameMap[field.name]);\n return new ArrowLikeSchema(selectedFields, this.metadata);\n }\n selectAt(...columnIndices) {\n // Ensure column indices reference valid fields\n const selectedFields = columnIndices.map((index) => this.fields[index]).filter(Boolean);\n return new ArrowLikeSchema(selectedFields, this.metadata);\n }\n assign(schemaOrFields) {\n let fields;\n let metadata = this.metadata;\n if (schemaOrFields instanceof ArrowLikeSchema) {\n const otherArrowLikeSchema = schemaOrFields;\n fields = otherArrowLikeSchema.fields;\n metadata = mergeMaps(mergeMaps(new Map(), this.metadata), otherArrowLikeSchema.metadata);\n }\n else {\n fields = schemaOrFields;\n }\n // Create a merged list of fields, overwrite fields in place, new fields at end\n const fieldMap = Object.create(null);\n for (const field of this.fields) {\n fieldMap[field.name] = field;\n }\n for (const field of fields) {\n fieldMap[field.name] = field;\n }\n const mergedFields = Object.values(fieldMap);\n return new ArrowLikeSchema(mergedFields, metadata);\n }\n}\n// Warn if any duplicated field names\n// function checkNames(fields: Field[]): void {\n// const usedNames: Record = {};\n// for (const field of fields) {\n// if (usedNames[field.name]) {\n// // eslint-disable-next-line\n// console.warn('ArrowLikeSchema: duplicated field name', field.name, field);\n// }\n// usedNames[field.name] = true;\n// }\n// }\nfunction mergeMaps(m1, m2) {\n // @ts-ignore\n return new Map([...(m1 || new Map()), ...(m2 || new Map())]);\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { getDataTypeFromArray, getDataTypeFromValue } from \"./data-type.js\";\n/**\n * SCHEMA SUPPORT - AUTODEDUCTION\n * @param {*} table\n * @param {*} schema\n * @returns\n */\nexport function deduceTableSchema(table) {\n switch (table.shape) {\n case 'array-row-table':\n case 'object-row-table':\n return deduceSchemaFromRows(table.data);\n case 'geojson-table':\n return deduceSchemaFromGeoJSON(table.features);\n case 'columnar-table':\n return deduceSchemaFromColumns(table.data);\n case 'arrow-table':\n default:\n throw new Error('Deduce schema');\n }\n}\nexport function deduceSchema(data) {\n return Array.isArray(data) ? deduceSchemaFromRows(data) : deduceSchemaFromColumns(data);\n}\n/** Given an object with columnar arrays, try to deduce a schema */\nfunction deduceSchemaFromColumns(columnarTable) {\n const fields = [];\n for (const [columnName, column] of Object.entries(columnarTable)) {\n const field = deduceFieldFromColumn(column, columnName);\n fields.push(field);\n }\n return { fields, metadata: {} };\n}\n/** Given an array of rows, try to deduce a schema */\nfunction deduceSchemaFromRows(rowTable) {\n if (!rowTable.length) {\n throw new Error('deduce from empty table');\n }\n const fields = [];\n const row0 = rowTable[0];\n // TODO - fields can be nullable, false detection...\n // Could look at additional rows if nulls in first row\n // TODO - if array, column names will be numbers\n for (const [columnName, value] of Object.entries(row0)) {\n fields.push(deduceFieldFromValue(value, columnName));\n }\n return { fields, metadata: {} };\n}\n/** Given a GeoJSON, try to deduce a schema */\nfunction deduceSchemaFromGeoJSON(features) {\n if (!features.length) {\n throw new Error('deduce from empty table');\n }\n const fields = [];\n const row0 = features[0].properties || {};\n // TODO - fields can be nullable, false detection...\n // Could look at additional rows if nulls in first row\n // TODO - if array, column names will be numbers\n for (const [columnName, value] of Object.entries(row0)) {\n fields.push(deduceFieldFromValue(value, columnName));\n }\n return { fields, metadata: {} };\n}\n/** Given a column (i.e. array), attempt to deduce an appropriate `Field` */\nfunction deduceFieldFromColumn(column, name) {\n if (ArrayBuffer.isView(column)) {\n const type = getDataTypeFromArray(column);\n return {\n name,\n type: type.type || 'null',\n nullable: type.nullable\n // metadata: {}\n };\n }\n if (Array.isArray(column) && column.length > 0) {\n const value = column[0];\n const type = getDataTypeFromValue(value);\n // TODO - support nested schemas?\n return {\n name,\n type,\n nullable: true\n // metadata: {},\n };\n }\n throw new Error('empty table');\n}\n/** Given a value, attempt to deduce an appropriate `Field` */\nfunction deduceFieldFromValue(value, name) {\n const type = getDataTypeFromValue(value);\n return {\n name,\n type,\n nullable: true\n // metadata: {}\n };\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { ArrowLikeSchema } from \"./arrow-like-schema.js\";\nimport { deduceTableSchema } from \"../simple-table/table-schema.js\";\nimport { getTableCell, getTableLength, getTableNumCols\n// getTableCell,\n// getTableRowShape,\n// getTableColumnIndex,\n// getTableColumnName,\n// getTableRowAsObject,\n// getTableRowAsArray\n } from \"../simple-table/table-accessors.js\";\nclass ArrowLikeVector {\n table;\n columnName;\n constructor(table, columnName) {\n this.table = table;\n this.columnName = columnName;\n }\n get(rowIndex) {\n return getTableCell(this.table, rowIndex, this.columnName);\n }\n toArray() {\n switch (this.table.shape) {\n case 'arrow-table':\n const arrowTable = this.table.data;\n return arrowTable.getChild(this.columnName)?.toArray();\n case 'columnar-table':\n return this.table.data[this.columnName];\n default:\n throw new Error(this.table.shape);\n }\n }\n}\n/**\n * Class that provides an API similar to Apache Arrow Table class\n * Forwards methods directly if the underlying table is Arrow, otherwise calls accessor functions\n */\nexport class ArrowLikeTable {\n schema;\n table;\n constructor(table) {\n const schema = table.schema || deduceTableSchema(table);\n this.schema = new ArrowLikeSchema(schema.fields, schema.metadata);\n this.table = { ...table, schema };\n }\n // get schema() {\n // return this.table.schema;\n // }\n get data() {\n return this.table.shape === 'geojson-table' ? this.table.features : this.table.data;\n }\n get numCols() {\n return getTableNumCols(this.table);\n }\n get length() {\n return getTableLength(this.table);\n }\n getChild(columnName) {\n return new ArrowLikeVector(this.table, columnName);\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { deduceTableSchema } from \"./table-schema.js\";\nexport function makeTableFromData(data) {\n let table;\n switch (getTableShapeFromData(data)) {\n case 'array-row-table':\n table = { shape: 'array-row-table', data: data };\n break;\n case 'object-row-table':\n table = { shape: 'object-row-table', data: data };\n break;\n case 'columnar-table':\n table = { shape: 'columnar-table', data: data };\n break;\n default:\n throw new Error('table');\n }\n const schema = deduceTableSchema(table);\n return { ...table, schema };\n}\n/** Helper function to get shape of data */\nfunction getTableShapeFromData(data) {\n if (Array.isArray(data)) {\n if (data.length === 0) {\n throw new Error('cannot deduce type of empty table');\n }\n // Deduce the table shape from the first row\n const firstRow = data[0];\n if (Array.isArray(firstRow)) {\n return 'array-row-table';\n }\n if (firstRow && typeof firstRow === 'object') {\n return 'object-row-table';\n }\n }\n if (data && typeof data === 'object') {\n return 'columnar-table';\n }\n throw new Error('invalid table');\n}\n/** Convert any table into object row format *\nexport function makeColumnarTable(table: Table): ColumnarTable {\n if (table.shape === 'columnar-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array<{[key: string]: unknown}>(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsObject(table, rowIndex);\n }\n return {\n shape: 'columnar-table',\n schema: table.schema,\n data\n };\n}\n\n\n/** Convert any table into array row format *\nexport function makeArrayRowTable(table: TableLike): ArrayRowTable {\n if (table.shape === 'array-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsArray(table, rowIndex);\n }\n return {\n shape: 'array-row-table',\n schema: table.schema,\n data\n };\n}\n\n/** Convert any table into object row format *\nexport function makeObjectRowTable(table: Table): ObjectRowTable {\n if (table.shape === 'object-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array<{[key: string]: unknown}>(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsObject(table, rowIndex);\n }\n return {\n shape: 'object-row-table',\n schema: table.schema,\n data\n };\n}\n*/\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { getTableLength } from \"./table-accessors.js\";\n/**\n * Returns an iterator that yields a single table as a sequence of batches.\n * @note Currently only a single batch is yielded.\n * @note All batches will have the same shape and schema as the original table.\n * @returns\n */\nexport function* makeBatchesFromTable(table) {\n yield makeBatchFromTable(table);\n}\n/**\n * Returns a table packaged as a single table batch\n * @note The batch will have the same shape and schema as the original table.\n * @returns `null` if no batches are yielded by the async iterator\n */\nexport function makeBatchFromTable(table) {\n return { ...table, length: getTableLength(table), batchType: 'data' };\n}\n/**\n * Assembles all batches from an async iterator into a single table.\n * @note All batches must have the same shape and schema\n * @param batchIterator\n * @returns `null` if no batches are yielded by the async iterator\n */\n// eslint-disable-next-line complexity\nexport async function makeTableFromBatches(batchIterator) {\n let arrayRows;\n let objectRows;\n let features;\n let shape = null;\n let schema;\n for await (const batch of batchIterator) {\n shape = shape || batch.shape;\n schema = schema || batch.schema;\n switch (batch.shape) {\n case 'array-row-table':\n arrayRows = arrayRows || [];\n for (let rowIndex = 0; rowIndex < getTableLength(batch); rowIndex++) {\n const row = batch.data[rowIndex];\n arrayRows.push(row);\n }\n break;\n case 'object-row-table':\n objectRows = objectRows || [];\n for (let rowIndex = 0; rowIndex < getTableLength(batch); rowIndex++) {\n const row = batch.data[rowIndex];\n objectRows.push(row);\n }\n break;\n case 'geojson-table':\n features = features || [];\n for (let rowIndex = 0; rowIndex < getTableLength(batch); rowIndex++) {\n const row = batch.features[rowIndex];\n features.push(row);\n }\n break;\n case 'columnar-table':\n case 'arrow-table':\n default:\n throw new Error('shape');\n }\n }\n if (!shape) {\n return null;\n }\n switch (shape) {\n case 'array-row-table':\n return { shape: 'array-row-table', data: arrayRows, schema };\n case 'object-row-table':\n return { shape: 'object-row-table', data: objectRows, schema };\n case 'geojson-table':\n return { shape: 'geojson-table', type: 'FeatureCollection', features: features, schema };\n default:\n return null;\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { getArrayTypeFromDataType } from \"./data-type.js\";\nexport function makeColumnFromField(field, length) {\n const ArrayType = getArrayTypeFromDataType(field.type, field.nullable);\n return new ArrayType(length);\n}\n/*\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nfunction deduceSchema(rows) {\n const row = rows[0];\n\n const schema = {};\n let i = 0;\n for (const columnName in row) {\n const value = row[columnName];\n switch (typeof value) {\n case 'number':\n case 'boolean':\n // TODO - booleans could be handled differently...\n schema[columnName] = {name: String(columnName), index: i, type: Float32Array};\n break;\n\n case 'object':\n schema[columnName] = {name: String(columnName), index: i, type: Array};\n break;\n\n case 'string':\n default:\n schema[columnName] = {name: String(columnName), index: i, type: Array};\n // We currently only handle numeric rows\n // TODO we could offer a function to map strings to numbers?\n }\n i++;\n }\n return schema;\n}\n*/\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { getTableCell, getTableLength, getTableRowAsArray, getTableRowAsObject } from \"./table-accessors.js\";\nimport { deduceTableSchema } from \"./table-schema.js\";\nimport { makeColumnFromField } from \"./table-column.js\";\n/**\n * Convert a table to a different shape\n * @param table\n * @param shape\n * @returns\n */\nexport function convertTable(table, shape) {\n switch (shape) {\n case 'object-row-table':\n return makeObjectRowTable(table);\n case 'array-row-table':\n return makeArrayRowTable(table);\n case 'columnar-table':\n return makeColumnarTable(table);\n case 'arrow-table':\n return makeArrowTable(table);\n default:\n throw new Error(shape);\n }\n}\n/**\n * Convert a table to apache arrow format\n * @note this depends on the `@loaders.gl/arrow module being imported\n */\nexport function makeArrowTable(table) {\n const _makeArrowTable = globalThis.__loaders?._makeArrowTable;\n if (!_makeArrowTable) {\n throw new Error('');\n }\n return _makeArrowTable(table);\n}\n/** Convert any simple table into columnar format */\nexport function makeColumnarTable(table) {\n // TODO - should schema really be optional?\n const schema = table.schema || deduceTableSchema(table);\n const fields = table.schema?.fields || [];\n if (table.shape === 'columnar-table') {\n return { ...table, schema };\n }\n const length = getTableLength(table);\n const columns = {};\n for (const field of fields) {\n const column = makeColumnFromField(field, length);\n columns[field.name] = column;\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n column[rowIndex] = getTableCell(table, rowIndex, field.name);\n }\n }\n return {\n shape: 'columnar-table',\n schema,\n data: columns\n };\n}\n/** Convert any table into array row format */\nexport function makeArrayRowTable(table) {\n if (table.shape === 'array-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsArray(table, rowIndex);\n }\n return {\n shape: 'array-row-table',\n schema: table.schema,\n data\n };\n}\n/** Convert any table into object row format */\nexport function makeObjectRowTable(table) {\n if (table.shape === 'object-row-table') {\n return table;\n }\n const length = getTableLength(table);\n const data = new Array(length);\n for (let rowIndex = 0; rowIndex < length; rowIndex++) {\n data[rowIndex] = getTableRowAsObject(table, rowIndex);\n }\n return {\n shape: 'object-row-table',\n schema: table.schema,\n data\n };\n}\n/**\n *\n * @note - should be part of schema module\n *\nexport function convertColumnarToRowFormatTable(columnarTable: ColumnarTable): ObjectRowTable {\n const tableKeys = Object.keys(columnarTable);\n const tableRowsCount = columnarTable[tableKeys[0]].length;\n\n const rowFormatTable: {}[] = [];\n\n for (let index = 0; index < tableRowsCount; index++) {\n const tableItem = {};\n for (let keyIndex = 0; keyIndex < tableKeys.length; keyIndex++) {\n const fieldName = tableKeys[keyIndex];\n tableItem[fieldName] = columnarTable[fieldName][index];\n }\n rowFormatTable.push(tableItem);\n }\n\n return {\n shape: 'object-row-table',\n schema: columnarTable.schema,\n data: rowFormatTable\n };\n}\n*/\n", "/**\n * Get number of vertices in mesh\n * @param attributes\n */\nexport function getMeshSize(attributes) {\n let size = 0;\n for (const attributeName in attributes) {\n const attribute = attributes[attributeName];\n if (ArrayBuffer.isView(attribute)) {\n // @ts-ignore DataView doesn't have BYTES_PER_ELEMENT\n size += attribute.byteLength * attribute.BYTES_PER_ELEMENT;\n }\n }\n return size;\n}\n/**\n * Get the (axis aligned) bounding box of a mesh\n * @param attributes\n * @returns array of two vectors representing the axis aligned bounding box\n */\n// eslint-disable-next-line complexity\nexport function getMeshBoundingBox(attributes) {\n let minX = Infinity;\n let minY = Infinity;\n let minZ = Infinity;\n let maxX = -Infinity;\n let maxY = -Infinity;\n let maxZ = -Infinity;\n const positions = attributes.POSITION ? attributes.POSITION.value : [];\n const len = positions && positions.length;\n for (let i = 0; i < len; i += 3) {\n const x = positions[i];\n const y = positions[i + 1];\n const z = positions[i + 2];\n minX = x < minX ? x : minX;\n minY = y < minY ? y : minY;\n minZ = z < minZ ? z : minZ;\n maxX = x > maxX ? x : maxX;\n maxY = y > maxY ? y : maxY;\n maxZ = z > maxZ ? z : maxZ;\n }\n return [\n [minX, minY, minZ],\n [maxX, maxY, maxZ]\n ];\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { getDataTypeFromTypedArray } from \"../table/simple-table/data-type.js\";\n/**\n * Create a schema for mesh attributes data\n * @param attributes\n * @param metadata\n * @returns\n */\nexport function deduceMeshSchema(attributes, metadata = {}) {\n const fields = deduceMeshFields(attributes);\n return { fields, metadata };\n}\n/**\n * Create arrow-like schema field for mesh attribute\n * @param attributeName\n * @param attribute\n * @param optionalMetadata\n * @returns\n */\nexport function deduceMeshField(name, attribute, optionalMetadata) {\n const type = getDataTypeFromTypedArray(attribute.value);\n const metadata = optionalMetadata ? optionalMetadata : makeMeshAttributeMetadata(attribute);\n return {\n name,\n type: { type: 'fixed-size-list', listSize: attribute.size, children: [{ name: 'value', type }] },\n nullable: false,\n metadata\n };\n}\n/**\n * Create fields array for mesh attributes\n * @param attributes\n * @returns\n */\nfunction deduceMeshFields(attributes) {\n const fields = [];\n for (const attributeName in attributes) {\n const attribute = attributes[attributeName];\n fields.push(deduceMeshField(attributeName, attribute));\n }\n return fields;\n}\n/**\n * Make metadata by mesh attribute properties\n * @param attribute\n * @returns\n */\nexport function makeMeshAttributeMetadata(attribute) {\n const result = {};\n if ('byteOffset' in attribute) {\n result.byteOffset = attribute.byteOffset.toString(10);\n }\n if ('byteStride' in attribute) {\n result.byteStride = attribute.byteStride.toString(10);\n }\n if ('normalized' in attribute) {\n result.normalized = attribute.normalized.toString();\n }\n return result;\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\n// This code is adapted from ArrowJS https://github.com/apache/arrow\n// under Apache license http://www.apache.org/licenses/LICENSE-2.0\n/**\n * Main data type enumeration.\n *\n * Data types in this library are all *logical*. They can be expressed as\n * either a primitive physical type (bytes or bits of some fixed size), a\n * nested type consisting of other data types, or another data type (e.g. a\n * timestamp encoded as an int64).\n *\n * **Note**: Only enum values 0-17 (NONE through Map) are written to an Arrow\n * IPC payload.\n *\n * The rest of the values are specified here so TypeScript can narrow the type\n * signatures further beyond the base Arrow Types. The Arrow DataTypes include\n * metadata like `bitWidth` that impact the type signatures of the values we\n * accept and return.\n *\n * For example, the `Int8Vector` reads 1-byte numbers from an `Int8Array`, an\n * `Int32Vector` reads a 4-byte number from an `Int32Array`, and an `Int64Vector`\n * reads a pair of 4-byte lo, hi 32-bit integers as a zero-copy slice from the\n * underlying `Int32Array`.\n *\n * Library consumers benefit by knowing the narrowest type, since we can ensure\n * the types across all public methods are propagated, and never bail to `any`.\n * These values are _never_ used at runtime, and they will _never_ be written\n * to the flatbuffers metadata of serialized Arrow IPC payloads.\n */\nexport var Type;\n(function (Type) {\n /** The default placeholder type */\n Type[Type[\"NONE\"] = 0] = \"NONE\";\n /** A NULL type having no physical storage */\n Type[Type[\"Null\"] = 1] = \"Null\";\n /** Signed or unsigned 8, 16, 32, or 64-bit little-endian integer */\n Type[Type[\"Int\"] = 2] = \"Int\";\n /** 2, 4, or 8-byte floating point value */\n Type[Type[\"Float\"] = 3] = \"Float\";\n /** Variable-length bytes (no guarantee of UTF8-ness) */\n Type[Type[\"Binary\"] = 4] = \"Binary\";\n /** UTF8 variable-length string as List */\n Type[Type[\"Utf8\"] = 5] = \"Utf8\";\n /** Boolean as 1 bit, LSB bit-packed ordering */\n Type[Type[\"Bool\"] = 6] = \"Bool\";\n /** Precision-and-scale-based decimal type. Storage type depends on the parameters. */\n Type[Type[\"Decimal\"] = 7] = \"Decimal\";\n /** int32_t days or int64_t milliseconds since the UNIX epoch */\n Type[Type[\"Date\"] = 8] = \"Date\";\n /** Time as signed 32 or 64-bit integer, representing either seconds, milliseconds, microseconds, or nanoseconds since midnight since midnight */\n Type[Type[\"Time\"] = 9] = \"Time\";\n /** Exact timestamp encoded with int64 since UNIX epoch (Default unit millisecond) */\n Type[Type[\"Timestamp\"] = 10] = \"Timestamp\";\n /** YEAR_MONTH or DAY_TIME interval in SQL style */\n Type[Type[\"Interval\"] = 11] = \"Interval\";\n /** A list of some logical data type */\n Type[Type[\"List\"] = 12] = \"List\";\n /** Struct of logical types */\n Type[Type[\"Struct\"] = 13] = \"Struct\";\n /** Union of logical types */\n Type[Type[\"Union\"] = 14] = \"Union\";\n /** Fixed-size binary. Each value occupies the same number of bytes */\n Type[Type[\"FixedSizeBinary\"] = 15] = \"FixedSizeBinary\";\n /** Fixed-size list. Each value occupies the same number of bytes */\n Type[Type[\"FixedSizeList\"] = 16] = \"FixedSizeList\";\n /** Map of named logical types */\n Type[Type[\"Map\"] = 17] = \"Map\";\n /** Dictionary aka Category type */\n Type[Type[\"Dictionary\"] = -1] = \"Dictionary\";\n Type[Type[\"Int8\"] = -2] = \"Int8\";\n Type[Type[\"Int16\"] = -3] = \"Int16\";\n Type[Type[\"Int32\"] = -4] = \"Int32\";\n Type[Type[\"Int64\"] = -5] = \"Int64\";\n Type[Type[\"Uint8\"] = -6] = \"Uint8\";\n Type[Type[\"Uint16\"] = -7] = \"Uint16\";\n Type[Type[\"Uint32\"] = -8] = \"Uint32\";\n Type[Type[\"Uint64\"] = -9] = \"Uint64\";\n Type[Type[\"Float16\"] = -10] = \"Float16\";\n Type[Type[\"Float32\"] = -11] = \"Float32\";\n Type[Type[\"Float64\"] = -12] = \"Float64\";\n Type[Type[\"DateDay\"] = -13] = \"DateDay\";\n Type[Type[\"DateMillisecond\"] = -14] = \"DateMillisecond\";\n Type[Type[\"TimestampSecond\"] = -15] = \"TimestampSecond\";\n Type[Type[\"TimestampMillisecond\"] = -16] = \"TimestampMillisecond\";\n Type[Type[\"TimestampMicrosecond\"] = -17] = \"TimestampMicrosecond\";\n Type[Type[\"TimestampNanosecond\"] = -18] = \"TimestampNanosecond\";\n Type[Type[\"TimeSecond\"] = -19] = \"TimeSecond\";\n Type[Type[\"TimeMillisecond\"] = -20] = \"TimeMillisecond\";\n Type[Type[\"TimeMicrosecond\"] = -21] = \"TimeMicrosecond\";\n Type[Type[\"TimeNanosecond\"] = -22] = \"TimeNanosecond\";\n Type[Type[\"DenseUnion\"] = -23] = \"DenseUnion\";\n Type[Type[\"SparseUnion\"] = -24] = \"SparseUnion\";\n Type[Type[\"IntervalDayTime\"] = -25] = \"IntervalDayTime\";\n Type[Type[\"IntervalYearMonth\"] = -26] = \"IntervalYearMonth\";\n})(Type || (Type = {}));\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\n// This code is adapted from ArrowJS https://github.com/apache/arrow\n// under Apache license http://www.apache.org/licenses/LICENSE-2.0\nimport { Type } from \"./enum.js\";\nexport { Type } from \"./enum.js\";\n/** ArrowLike DataType class */\nexport class DataType {\n static isNull(x) {\n return x && x.typeId === Type.Null;\n }\n static isInt(x) {\n return x && x.typeId === Type.Int;\n }\n static isFloat(x) {\n return x && x.typeId === Type.Float;\n }\n static isBinary(x) {\n return x && x.typeId === Type.Binary;\n }\n static isUtf8(x) {\n return x && x.typeId === Type.Utf8;\n }\n static isBool(x) {\n return x && x.typeId === Type.Bool;\n }\n static isDecimal(x) {\n return x && x.typeId === Type.Decimal;\n }\n static isDate(x) {\n return x && x.typeId === Type.Date;\n }\n static isTime(x) {\n return x && x.typeId === Type.Time;\n }\n static isTimestamp(x) {\n return x && x.typeId === Type.Timestamp;\n }\n static isInterval(x) {\n return x && x.typeId === Type.Interval;\n }\n static isList(x) {\n return x && x.typeId === Type.List;\n }\n static isStruct(x) {\n return x && x.typeId === Type.Struct;\n }\n static isUnion(x) {\n return x && x.typeId === Type.Union;\n }\n static isFixedSizeBinary(x) {\n return x && x.typeId === Type.FixedSizeBinary;\n }\n static isFixedSizeList(x) {\n return x && x.typeId === Type.FixedSizeList;\n }\n static isMap(x) {\n return x && x.typeId === Type.Map;\n }\n static isDictionary(x) {\n return x && x.typeId === Type.Dictionary;\n }\n get typeId() {\n return Type.NONE;\n }\n // get ArrayType(): AnyArrayType {\n // return Int8Array;\n // }\n // get ArrayType() { return Array; }\n compareTo(other) {\n // TODO\n return this === other; // comparer.visit(this, other);\n }\n}\n// NULL\nexport class Null extends DataType {\n get typeId() {\n return Type.Null;\n }\n get [Symbol.toStringTag]() {\n return 'Null';\n }\n toString() {\n return 'Null';\n }\n}\n// BOOLEANS\nexport class Bool extends DataType {\n get typeId() {\n return Type.Bool;\n }\n // get ArrayType() {\n // return Uint8Array;\n // }\n get [Symbol.toStringTag]() {\n return 'Bool';\n }\n toString() {\n return 'Bool';\n }\n}\n// INTS\nexport class Int extends DataType {\n isSigned;\n bitWidth;\n constructor(isSigned, bitWidth) {\n super();\n this.isSigned = isSigned;\n this.bitWidth = bitWidth;\n }\n get typeId() {\n return Type.Int;\n }\n // get ArrayType() {\n // switch (this.bitWidth) {\n // case 8:\n // return this.isSigned ? Int8Array : Uint8Array;\n // case 16:\n // return this.isSigned ? Int16Array : Uint16Array;\n // case 32:\n // return this.isSigned ? Int32Array : Uint32Array;\n // case 64:\n // return this.isSigned ? Int32Array : Uint32Array;\n // default:\n // throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`);\n // }\n // }\n get [Symbol.toStringTag]() {\n return 'Int';\n }\n toString() {\n return `${this.isSigned ? 'I' : 'Ui'}nt${this.bitWidth}`;\n }\n}\nexport class Int8 extends Int {\n constructor() {\n super(true, 8);\n }\n}\nexport class Int16 extends Int {\n constructor() {\n super(true, 16);\n }\n}\nexport class Int32 extends Int {\n constructor() {\n super(true, 32);\n }\n}\nexport class Int64 extends Int {\n constructor() {\n super(true, 64);\n }\n}\nexport class Uint8 extends Int {\n constructor() {\n super(false, 8);\n }\n}\nexport class Uint16 extends Int {\n constructor() {\n super(false, 16);\n }\n}\nexport class Uint32 extends Int {\n constructor() {\n super(false, 32);\n }\n}\nexport class Uint64 extends Int {\n constructor() {\n super(false, 64);\n }\n}\n// FLOATS\nconst Precision = {\n HALF: 16,\n SINGLE: 32,\n DOUBLE: 64\n};\nexport class Float extends DataType {\n precision;\n constructor(precision) {\n super();\n this.precision = precision;\n }\n get typeId() {\n return Type.Float;\n }\n // get ArrayType() {\n // switch (this.precision) {\n // case Precision.HALF:\n // return Uint16Array;\n // case Precision.SINGLE:\n // return Float32Array;\n // case Precision.DOUBLE:\n // return Float64Array;\n // default:\n // throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`);\n // }\n // }\n get [Symbol.toStringTag]() {\n return 'Float';\n }\n toString() {\n return `Float${this.precision}`;\n }\n}\nexport class Float16 extends Float {\n constructor() {\n super(Precision.HALF);\n }\n}\nexport class Float32 extends Float {\n constructor() {\n super(Precision.SINGLE);\n }\n}\nexport class Float64 extends Float {\n constructor() {\n super(Precision.DOUBLE);\n }\n}\nexport class Binary extends DataType {\n constructor() {\n super();\n }\n get typeId() {\n return Type.Binary;\n }\n toString() {\n return 'Binary';\n }\n get [Symbol.toStringTag]() {\n return 'Binary';\n }\n}\n// STRINGS\nexport class Utf8 extends DataType {\n get typeId() {\n return Type.Utf8;\n }\n // get ArrayType() {\n // return Uint8Array;\n // }\n get [Symbol.toStringTag]() {\n return 'Utf8';\n }\n toString() {\n return 'Utf8';\n }\n}\n// DATES, TIMES AND INTERVALS\nconst DateUnit = {\n DAY: 0,\n MILLISECOND: 1\n};\nexport class Date extends DataType {\n unit;\n constructor(unit) {\n super();\n this.unit = unit;\n }\n get typeId() {\n return Type.Date;\n }\n // get ArrayType() {\n // return Int32Array;\n // }\n get [Symbol.toStringTag]() {\n return 'Date';\n }\n toString() {\n return `Date${(this.unit + 1) * 32}<${DateUnit[this.unit]}>`;\n }\n}\nexport class DateDay extends Date {\n constructor() {\n super(DateUnit.DAY);\n }\n}\nexport class DateMillisecond extends Date {\n constructor() {\n super(DateUnit.MILLISECOND);\n }\n}\nconst TimeUnit = {\n SECOND: 1,\n MILLISECOND: 1e3,\n MICROSECOND: 1e6,\n NANOSECOND: 1e9\n};\nexport class Time extends DataType {\n unit;\n bitWidth;\n constructor(unit, bitWidth) {\n super();\n this.unit = unit;\n this.bitWidth = bitWidth;\n }\n get typeId() {\n return Type.Time;\n }\n toString() {\n return `Time${this.bitWidth}<${TimeUnit[this.unit]}>`;\n }\n get [Symbol.toStringTag]() {\n return 'Time';\n }\n}\nexport class TimeSecond extends Time {\n constructor() {\n super(TimeUnit.SECOND, 32);\n }\n}\nexport class TimeMillisecond extends Time {\n constructor() {\n super(TimeUnit.MILLISECOND, 32);\n }\n}\n// export class TimeMicrosecond extends Time { constructor() { super(TimeUnit.MICROSECOND, 64); } }\n// export class TimeNanosecond extends Time { constructor() { super(TimeUnit.NANOSECOND, 64); } }\nexport class Timestamp extends DataType {\n unit;\n timezone;\n constructor(unit, timezone = null) {\n super();\n this.unit = unit;\n this.timezone = timezone;\n }\n get typeId() {\n return Type.Timestamp;\n }\n // get ArrayType() {\n // return Int32Array;\n // }\n get [Symbol.toStringTag]() {\n return 'Timestamp';\n }\n toString() {\n return `Timestamp<${TimeUnit[this.unit]}${this.timezone ? `, ${this.timezone}` : ''}>`;\n }\n}\nexport class TimestampSecond extends Timestamp {\n constructor(timezone = null) {\n super(TimeUnit.SECOND, timezone);\n }\n}\nexport class TimestampMillisecond extends Timestamp {\n constructor(timezone = null) {\n super(TimeUnit.MILLISECOND, timezone);\n }\n}\nexport class TimestampMicrosecond extends Timestamp {\n constructor(timezone = null) {\n super(TimeUnit.MICROSECOND, timezone);\n }\n}\nexport class TimestampNanosecond extends Timestamp {\n constructor(timezone = null) {\n super(TimeUnit.NANOSECOND, timezone);\n }\n}\nconst IntervalUnit = {\n DAY_TIME: 0,\n YEAR_MONTH: 1\n};\nexport class Interval extends DataType {\n unit;\n constructor(unit) {\n super();\n this.unit = unit;\n }\n get typeId() {\n return Type.Interval;\n }\n // get ArrayType() {\n // return Int32Array;\n // }\n get [Symbol.toStringTag]() {\n return 'Interval';\n }\n toString() {\n return `Interval<${IntervalUnit[this.unit]}>`;\n }\n}\nexport class IntervalDayTime extends Interval {\n constructor() {\n super(IntervalUnit.DAY_TIME);\n }\n}\nexport class IntervalYearMonth extends Interval {\n constructor() {\n super(IntervalUnit.YEAR_MONTH);\n }\n}\nexport class FixedSizeList extends DataType {\n listSize;\n children;\n constructor(listSize, child) {\n super();\n this.listSize = listSize;\n this.children = [child];\n }\n get typeId() {\n return Type.FixedSizeList;\n }\n get valueType() {\n return this.children[0].type;\n }\n get valueField() {\n return this.children[0];\n }\n // get ArrayType() {\n // return this.valueType.ArrayType;\n // }\n get [Symbol.toStringTag]() {\n return 'FixedSizeList';\n }\n toString() {\n return `FixedSizeList[${this.listSize}]<${JSON.stringify(this.valueType)}>`;\n }\n}\nexport class Struct extends DataType {\n children;\n constructor(children) {\n super();\n this.children = children;\n }\n get typeId() {\n return Type.Struct;\n }\n toString() {\n return `Struct<{${this.children\n .map((f) => `${f.name}:${JSON.stringify(f.type)}`)\n .join(', ')}}>`;\n }\n get [Symbol.toStringTag]() {\n return 'Struct';\n }\n}\n", "// loaders.gl\n// SPDX-License-Identifier: MIT\n// Copyright (c) vis.gl contributors\nimport { Type } from \"./arrow-like-type.js\";\n/**\n * Gets type information from an Arrow type object or \"mock\" Arrow type object\n * @param arrowTypeLike Arrow Type or type object of similar shape\n */\nexport function getTypeInfo(arrowTypeLike) {\n return {\n typeId: arrowTypeLike.typeId,\n ArrayType: arrowTypeLike.ArrayType,\n typeName: arrowTypeLike.toString(),\n typeEnumName: getTypeKey(arrowTypeLike.typeId),\n precision: arrowTypeLike.precision\n };\n}\nlet ReverseType = null;\nfunction getTypeKey(typeKey) {\n if (!ReverseType) {\n ReverseType = {};\n for (const key in Type) {\n ReverseType[Type[key]] = key;\n }\n }\n return ReverseType[typeKey];\n}\n", "// From https://github.com/rauschma/async-iter-demo/tree/master/src under MIT license\n// http://2ality.com/2016/10/asynchronous-iteration.html\nclass ArrayQueue extends Array {\n enqueue(value) {\n // Add at the end\n return this.push(value);\n }\n dequeue() {\n // Remove first element\n return this.shift();\n }\n}\nexport default class AsyncQueue {\n _values;\n _settlers;\n _closed;\n constructor() {\n // enqueues > dequeues\n this._values = new ArrayQueue();\n // dequeues > enqueues\n this._settlers = new ArrayQueue();\n this._closed = false;\n }\n close() {\n while (this._settlers.length > 0) {\n this._settlers.dequeue().resolve({ done: true });\n }\n this._closed = true;\n }\n [Symbol.asyncIterator]() {\n return this;\n }\n enqueue(value) {\n if (this._closed) {\n throw new Error('Closed');\n }\n if (this._settlers.length > 0) {\n if (this._values.length > 0) {\n throw new Error('Illegal internal state');\n }\n const settler = this._settlers.dequeue();\n if (value instanceof Error) {\n settler.reject(value);\n }\n else {\n settler.resolve({ value });\n }\n }\n else {\n this._values.enqueue(value);\n }\n }\n /**\n * @returns a Promise for an IteratorResult\n */\n next() {\n if (this._values.length > 0) {\n const value = this._values.dequeue();\n if (value instanceof Error) {\n return Promise.reject(value);\n }\n return Promise.resolve({ value });\n }\n if (this._closed) {\n if (this._settlers.length > 0) {\n throw new Error('Illegal internal state');\n }\n return Promise.resolve({ done: true });\n }\n // Wait for new values to be enqueued\n return new Promise((resolve, reject) => {\n this._settlers.enqueue({ resolve, reject });\n });\n }\n}\n/**\n * @returns a Promise for an Array with the elements in `asyncIterable`\n */\nexport async function takeAsync(asyncIterable, count = Infinity) {\n const result = [];\n const iterator = asyncIterable[Symbol.asyncIterator]();\n while (result.length < count) {\n const { value, done } = await iterator.next();\n if (done) {\n break;\n }\n result.push(value);\n }\n return result;\n}\n"], "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,cAAAA;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA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