Automatic image creation for training AI


RE: Automatic image creation for training AI
#6
(2021-07-05, 17:01)Jose Alfonso Wrote: Look at this example of command line with LDView:

LDVIEW_PATH/LDView.exe LDRAWBRICK.dat -SaveWidth=160 -SaveHeight=120 -DefaultLatLong=45,30 -SaveSnapshot=IMAGE.png -AutoCrop=1 -SaveZoomToFit=1 -SaveAlpha=1 -LineSmoothing=1 -DefaultColor3=0xBFBFBF -FOV=0.1 -LightVector=-0.125,0.125,1

For example, "SaveZoonToFit=1" zooms until the brick touches one of the borders of the image. I think this is good for AI training, at least when labelling for object detection. "AutoCrop=1" crops the image to the brick, so the result can be 130x120 pixels or 160x100 instead of the maximum 160x120. Maybe you should remove that option. With DefaultLatLong you change the angle, and with DefaultColor3 you set the color of the brick.

Other parameters are read from the configuration of LDView. For your task you should unmark "Edge lines" in Geometry tab to avoid artificial edges.

I had a quick look at getting this working (which I couldn't quite figure out yet,  command line as in command prompt?)  but I noticed that the parts don't have names like 1x1 plate,  is that in another database somewhere for the names?
I was using the complete parts library that I downloaded not a local one installed with LDraw\Lecad\MLcad mostly because I couldn't find them.
Reply
« Next Oldest | Next Newest »



Messages In This Thread
RE: Automatic image creation for training AI - by Murray - 2021-07-06, 15:03

Forum Jump:


Users browsing this thread: 1 Guest(s)