aurora-opensource / xviz

A protocol for real-time transfer and visualization of autonomy data
http://xviz.io
Apache License 2.0
1.02k stars 229 forks source link

Convert KITTI to XVIZ - TypeError: (0, _loaderUtils.padTo4Bytes) is not a function #684

Closed olivia-sp closed 2 years ago

olivia-sp commented 2 years ago

I'm trying to convert KITTI to XVIZ format when I run

yarn start -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync

then type error occurs,, how can I fix it?

=================================

yarn run v1.22.17 warning package.json: No license field $ node ./src/index.js -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync Converting KITTI data at ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync Saving to ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync **D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\dist\es5\gltf\glb-builder.js:111 this.byteLength += (0, _loaderUtils.padTo4Bytes)(byteLength); ^

TypeError: (0 , _loaderUtils.padTo4Bytes) is not a function** at GLTFBuilder.addBufferView (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\gltf\glb-builder.js:135:24) at GLTFBuilder.addBuffer (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\gltf\glb-builder.js:105:34) at packBinaryJsonTypedArray (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:24:35) at packBinaryJson (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:58:12) at packBinaryJson (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:68:24) at map (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:49:36) at Array.map () at packBinaryJson (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:49:21) at packBinaryJson (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:68:24) at packBinaryJson (D:\0_GIT\xviz_kuta\examples\converters\kitti\node_modules\@xviz\io\src\writers\xviz-pack-binary.js:68:24)

Node.js v17.4.0 error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

twojtasz commented 2 years ago

This is a loaders.gl issue, I think a work around is to fix the version. Let me find the specific details for you

On Tue, Jan 25, 2022, 03:32 olivia-sp @.***> wrote:

I'm trying to convert KITTI to XVIZ format when I run

yarn start -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync

then type error occurs,, how can I fix it?

=================================

yarn run v1.22.17 warning package.json: No license field $ node ./src/index.js -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync Converting KITTI data at ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync Saving to ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync @.*** \io\dist\es5\gltf\glb-builder.js:111 this.byteLength += (0, _loaderUtils.padTo4Bytes)(byteLength); ^

TypeError: (0 , _loaderUtils.padTo4Bytes) is not a function at GLTFBuilder.addBufferView **@. \io\src\gltf\glb-builder.js:135:24) at GLTFBuilder.addBuffer @. \io\src\gltf\glb-builder.js:105:34) at packBinaryJsonTypedArray @. \io\src\writers\xviz-pack-binary.js:24:35) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:58:12) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at map @. \io\src\writers\xviz-pack-binary.js:49:36) at Array.map () at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:49:21) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at packBinaryJson @.*** \io\src\writers\xviz-pack-binary.js:68:24)

Node.js v17.4.0 error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

— Reply to this email directly, view it on GitHub https://github.com/aurora-opensource/xviz/issues/684, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALUBXFEMY6NAFKMZRXM3V3UX2C57ANCNFSM5MX74EDQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you are subscribed to this thread.Message ID: @.***>

rty813 commented 2 years ago

This is a loaders.gl issue, I think a work around is to fix the version. Let me find the specific details for you On Tue, Jan 25, 2022, 03:32 olivia-sp @.> wrote: I'm trying to convert KITTI to XVIZ format when I run yarn start -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync then type error occurs,, how can I fix it? ================================= yarn run v1.22.17 warning package.json: No license field $ node ./src/index.js -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync Converting KITTI data at ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync Saving to ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync @. \io\dist\es5\gltf\glb-builder.js:111 this.byteLength += (0, _loaderUtils.padTo4Bytes)(byteLength); ^ TypeError: (0 , _loaderUtils.padTo4Bytes) is not a function at GLTFBuilder.addBufferView **@. \io\src\gltf\glb-builder.js:135:24) at GLTFBuilder.addBuffer @. \io\src\gltf\glb-builder.js:105:34) at packBinaryJsonTypedArray @. \io\src\writers\xviz-pack-binary.js:24:35) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:58:12) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at map @. \io\src\writers\xviz-pack-binary.js:49:36) at Array.map () at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:49:21) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) Node.js v17.4.0 error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. — Reply to this email directly, view it on GitHub <#684>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALUBXFEMY6NAFKMZRXM3V3UX2C57ANCNFSM5MX74EDQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you are subscribed to this thread.Message ID: @.>

Is this issue fixed?

twojtasz commented 2 years ago

Let me fix that in a few hours

On Sun, Apr 24, 2022, 18:05 豆腐 @.***> wrote:

This is a loaders.gl issue, I think a work around is to fix the version. Let me find the specific details for you … <#m-3317499830209434795> On Tue, Jan 25, 2022, 03:32 olivia-sp @.> wrote: I'm trying to convert KITTI to XVIZ format when I run yarn start -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync then type error occurs,, how can I fix it? ================================= yarn run v1.22.17 warning package.json: No license field $ node ./src/index.js -d ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync -o ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync Converting KITTI data at ../../../data/kitti/2011_09_26/2011_09_26_drive_0005_sync Saving to ../../../data/generated/kitti/2011_09_26/2011_09_26_drive_0005_sync @. \io\dist\es5\gltf\glb-builder.js:111 this.byteLength += (0, _loaderUtils.padTo4Bytes)(byteLength); ^ TypeError: (0 , _loaderUtils.padTo4Bytes) is not a function at GLTFBuilder.addBufferView @.** \io\src\gltf\glb-builder.js:135:24) at GLTFBuilder.addBuffer @. \io\src\gltf\glb-builder.js:105:34) at packBinaryJsonTypedArray @. \io\src\writers\xviz-pack-binary.js:24:35) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:58:12) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at map @. \io\src\writers\xviz-pack-binary.js:49:36) at Array.map () at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:49:21) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) at packBinaryJson @. \io\src\writers\xviz-pack-binary.js:68:24) Node.js v17.4.0 error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. — Reply to this email directly, view it on GitHub <#684 https://github.com/aurora-opensource/xviz/issues/684>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALUBXFEMY6NAFKMZRXM3V3UX2C57ANCNFSM5MX74EDQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you are subscribed to this thread.Message ID: @.>

Is this issue fixed?

— Reply to this email directly, view it on GitHub https://github.com/aurora-opensource/xviz/issues/684#issuecomment-1107961130, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALUBXEZ5EPPI27V7W7BLDLVGXVVRANCNFSM5MX74EDQ . You are receiving this because you commented.Message ID: @.***>

twojtasz commented 2 years ago

@rty813 can you try again after pulling down master, which should be @xviz 1.0.11

twojtasz commented 2 years ago

This should be fixed. Please re-open if problem persists after pulling down the latest master or using the latest release.