ChrisWu1997 / onshape-cad-parser

34 stars 7 forks source link

About parsing Fushion 360 dataset #1

Closed Ma-Weijian closed 2 years ago

Ma-Weijian commented 2 years ago

HI Chris,

In the appendix of DeepCAD I've noticed that you have tested your model on Fushion 360 dataset and have received satisfying results. This shows the transferability of DeepCAD on multiple data sources.

However, as Autodesk has updated Fushion 360, I want to make sure the exact part of Fushion 360 you use. Is your test performed on the reconstruction part of Fushion 360 following this link: https://fusion-360-gallery-dataset.s3.us-west-2.amazonaws.com/reconstruction/r1.0.1/r1.0.1.zip ? In the additional downloads I also discovered two relavant files named Reconstruction Dataset Extrude Volumes and Reconstruction Dataset Face Extrusion Sequences, are they necessary for the tests?

When I downloaded and unzipped the reconstruction part, I found multiple files for each CAD model. I tried to convert the json files into vectors using the json2vec.py. During the conversion I discovered some CAD sequences exceeding the maximal length defined in the macros and some using curves not mentioned by DeepCAD. I also wonder how to deal with these cases?

Thanks and best regards.

ChrisWu1997 commented 2 years ago

Is your test performed on the reconstruction part of Fushion 360 following this link: https://fusion-360-gallery-dataset.s3.us-west-2.amazonaws.com/reconstruction/r1.0.1/r1.0.1.zip ?

I double checked my code and we used r1.0.0 by that time. I think it's fine to use r1.0.1, there shouldn't be much difference.

In the additional downloads I also discovered two relavant files named Reconstruction Dataset Extrude Volumes and Reconstruction Dataset Face Extrusion Sequences, are they necessary for the tests?

I believe they are not necessary.

During the conversion I discovered some CAD sequences exceeding the maximal length defined in the macros and some using curves not mentioned by DeepCAD. I also wonder how to deal with these cases?

We simply discard those files as we did for OnShape data.

If you want to train on Fusion 360 data, then simply just go ahead using json2vec.py to convert to vectors and then train the model. If you just want to run the released model (pretrained on our onshape data) on Fusion 360 data, there are some tricky things. Basically, we found onshape data and fusion 360 data follow some different conventions. For example, onshape data mostly draw sketch on XY plane and fusion 360 mostly on XZ plane (I may remember this wrong, but the point is that there is a mismatch). So this different convention creates an unwanted distribution shift for the data. For our test in the supplementary, we manually align the data by doing some rigid transformations, before converting the json to vectors. If you want to do this, let me know and I can email you the code file.

Ma-Weijian commented 2 years ago

If you want to train on Fusion 360 data, then simply just go ahead using json2vec.py to convert to vectors and then train the model. If you just want to run the released model (pretrained on our onshape data) on Fusion 360 data, there are some tricky things. Basically, we found onshape data and fusion 360 data follow some different conventions. For example, onshape data mostly draw sketch on XY plane and fusion 360 mostly on XZ plane (I may remember this wrong, but the point is that there is a mismatch). So this different convention creates an unwanted distribution shift for the data. For our test in the supplementary, we manually align the data by doing some rigid transformations, before converting the json to vectors. If you want to do this, let me know and I can email you the code file.

Oh, it turns out that there's a mismatch between onshape and fushon 360 data. I think I need the conversion code to fit fushion 360 data into the pretrained models.

You can send the code to maweijian1999@126.com at your convenience.

Thanks a lot

ChrisWu1997 commented 2 years ago

Sent.

Ma-Weijian commented 2 years ago

Thanks a lot for the code!

hanyong-max commented 1 year ago

@ChrisWu1997 ,麻烦方便的时候发一份代码给我,邮箱:498608832@qq.com

hanyong-max commented 1 year ago

@Ma-Weijian ,方便发一份代码给我吗,邮箱:498608832@qq.com

Wsyhw commented 7 months ago

@ChrisWu1997 方便方便的时候发一份代码给我,邮箱:y_wsy09@sjtu.edu.cn