From Landscape XYZ Point Data to *.STL to Rapid Prototype (part I)

Considering I haven’t sent the finished model to be vetted by the Professor who runs the rapid prototyping machine, this can only be the first part of hopefully a short series.

To continue my quest to use laser scanning to model and then reproduce important fossils, I was given a sample dataset to format correctly and then send over to the Mechanical Engineering Department to test out their rapid prototyping machine. This dataset is a landscape model (I believe based on a DEM) made of point data in an XYZ file. To explain, the surface is made up of a series of points positioned by x-axis, y-axis, and z-axis triplets. In the end, I needed a solid model in *.STL format. Although I was told to use AutoCAD for this, I think I’ve found another (free) way.

I planned to import the data file into the free, open-source point-meshing program Meshlab v. 1.2.3 and manipulate it there, but I needed to change the file format correctly first. Originally, I used the MS-DOS program xyz2vrml.exe (from this useful site) to convert the data text file into a *.WRL (VRML) file, but then I realized I could just change the file extension and Meshlab would be able to read and import the points (this of course only works if your data file just has a different extension than Meshlab expects, not if the data are a different type).

modeling 1
Adding point landscape data to Meshlab.

To convert the point data to a mesh (TIN) surface, I used the Surface Reconstruction: Ball Pivoting filter (in the Remeshing, simplification and reconstruction menu) with the default settings (world unit: 0.0, perc on 0.0, clustering radius: 20, angle threshold: 90). To see the result I had to click the Wireframe button in Meshlab to get a surface made of triangles. The file was saved in *.3DS format.

modeling 2
Wireframe after meshing.

The *.3DS file was then imported into Google Sketchup for modeling. Although the mesh seemed to act like a single object, attempting to use certain tools made me realize that it was being manipulated as a collection of triangles, which meant I couldn’t use such things as the Push/Pull tool to extrude the surface down to a lower plane to create a solid model. Luckily I found a Sketchup plugin to let me do something similar (available here). The Curviloft plugin allowed me to fill in space between a rectangular base (easily drawn in Sketchup) and the meshed landscape surface above it.

modeling 3
Adding mesh to Google Sketchup.

I used the Skin Contours tool on each of the four remaining sides to achieve a solid model. To do this, I drew a line connecting the corner of the base rectangle to the corner of the mesh above it. Once a side had been marked this way, I used the Skin Contours tool to select each edge of what the new face was going to be and clicked the checkbox. In order to select adjacent mesh edges, the Extend Selection toolbar button needed to be on, and the Stop Prolongation button needed to be off.

modeling 6
Adding a base and connecting it to the mesh at the corners.

 

modeling 8
One side completed.

modeling 4 modeling 5

To get the final file format correct (I’m hoping), I had to export the model from Sketchup as a COLLADA (*.DAE) file, then into Meshlab, and then use Meshlab to save into *.STL. I was told that my *.STL file needs to be “solid,” but I’m not sure whether this simply means “no holes” or whether there is a trick to completely fill the model with some virtual material (Unobtanium? Adamantium?). I’ll send this model to the Professor of Rapid Prototyping (not his real title, unfortunately) and see what sort of feedback he has. Tune in next time for the exciting conclusion!

modeling 9
The finished model in Google Sketchup.

Total project time (including learning Sketchup and Meshlab and designing the workflow): several hours.
Writeup time: 1.5 hours

 

[activity] 2010 North Dakota EPSCoR Conference

I attended the 2010 North Dakota EPSCoR (Experimental Program to Stimulate Competitive Research) Conference yesterday to see the work of some of my fellow students, but did not submit a poster. There is a good summary here.

UND Geology and Geological Engineering presenters:
– Ted Bibby and Jaakko Putkonen – Landscape evolution of ice free valleys, central Antarctica
– Nic Buer and Phil Gerla – Comparison of nutrient transport and concentration between an invasive-dominated, disturbed wetland and a natural sedge meadow wetland in northwestern Minnesota
– Chase Christenson and Scott Korom – Denitrification at the Oakes Irrigation Test Area, Dickey County, ND
– Rob Klenner and Will Gosnold – Reevaluating terrestrial heat flow in Minnesota
– Risa Madoff, Ted Bibby, Megan Miller and Jaakko Putkonen – Hillslope evolution quantified with digital laser scanning in eastern Sierra Nevada, CA
– Megan Miller, Risa Madoff, Ted Bibby and Jaakko Putkonen – Photo analysis of landscape change in the eastern Sierra Nevada mountains, California
– Karew Schumaker, Matt Weiler, Joseph Hartman and Allen Kihm – Geology and preliminary paleontology of the Cvancara locality (Paleocene), Tongue River Member of the Fort Union Formation, Grant County, North Dakota
– Vladimir Zivkovic and Will Gosnold – A multiple method geophysical investigation of the northeastern rim of the St. Martin impact structure, Manitoba, Canada

Other posters of note (among many)
– Janna Mabey and Becky Simmons – Phylogeny and generic revision of the Tiger Moth genus Phoenicoprocta (Noctuidae: Arctiinae: Euchromiina) for use in examining the evolution of male courtship signals
– Andy Magness, J.M. Hicks, C. Desgranges and J. Delhommelle – Phase equilibria of polyaromatic hydrocarbons by Hybrid Monte Carlo Wang-Landau simulations

ND EPSCoR State Conference 2010 in Grand Forks

I spent this morning and early afternoon at the North Dakota EPSCoR 2010 State Conference. EPSCoR (Experimental Program to Stimulate Competitive Research) is a federally funded program to fund states that need additional infrastructure in order to improve their research output. It is funded competitively, and then those funds are distributed within the state towards research projects, facilities, and scholarships. I learned today that North Dakota is the only state that has been funded continuously since the program’s inception in the early 80s. Part of this is supposedly because the state agrees up front beforehand to match the federal money given, something I guess other states aren’t able to do.

The posters (graduate student research projects) were generally very good, although a lot of walking was involved to see everything because of placement on the walls down the main corridor of the Alerus Center. Several of my Geology and Geological Engineering colleagues presented posters, most of them luckily in high-traffic areas. A lot of the material was biochemical in nature, which tended to make me (since I’m not a chemical biologist) gloss over some things I probably shouldn’t have; I would suggest to EPSCoR that in the future the posters be arranged more according to topic, which might have the added benefit of getting students from different institutions to talk to each other about their similar topics.

I’ve scanned the poster session program (includes abstracts), and for general entertainment I shot some photos, shared below.

IMG_7323 crop
A geologist explains his project.
IMG_7326
Breakfast, the introductory speaker, and some of the many posters were on display in this room.

IMG_7336 crop
Student posters went all the way down the hall.
IMG_7338 crop
A biologist explains her work.
IMG_7346
Lunch was surprisingly good for being free.
 


To do: make sure I have a list here of all the GGE students who presented.

Problems with Tiddlywiki with Opera 10.70 (build 9047) for Mac

At some point in the last few days (actually it looks like since the 18th of September), Opera has quit being able to save my TiddlyWiki files–in fact it appears that all the notes I made for my dissertation on Monday have disappeared, even though I thought I was autosaving. I’m more than slightly miffed about this.

At present, it looks like TiddlyWiki works fine in Safari and Camino (the browser from which I just switched because it uses up most of my CPU). In Opera, however, I get this error:

The original file ’empty.html’ does not appear to be a valid TiddlyWiki

and the file will not save. For some reason, the dialog box asking for permission for the security certificate has also stopped appearing, while in other browsers it comes up for each new TiddlyWiki file I open.

I’ve looked into this as much as I wish but I cannot find a solution. The problem may be with Java (somehow?), or with this particular build of Opera (I think I am on a nightly build because I wanted some of the new functionality). In any case, I’m stymied by the lack of ability to really manage the security certificates, especially when they don’t pop up. I’ll be using Safari as my TiddlyWiki browser until I figure out what the issue is or things suddenly start working again in Opera.

Laser-Scanning Small Objects with a Leica Scanstation

As previously mentioned, we have a Leica Scanstation here at UND that is used for scanning large areas for geomorphology projects. I borrowed it yesterday to try out how it did at close range. Although I probably don’t need to say this, things did not go as well as well as planned.

First, the setup:
IMG_7179
Since we’re neither scanning a large area nor worrying about repeatability, there was no need for a leveled tripod or targets. The metal base of the scanner is designed for these sorts of applications, so no harm is being done by setting it down on the table like this. The bricks are used to keep the specimen up in front of the scanner, and the computer runs the whole setup. You can see the Triceratops “model” and the gastropod (snail) specimen as well, to judge their size:
IMG_7181
IMG_7180

I’ll skip over the mechanics of scanning, except to mention that the Leica licensing system is still giving us problems; under one Windows 7 account I couldn’t access the license but under another I could. Such is life with computers!

The problems came from trying to scan at very fine detail. The scanner was set up just under 0.5 m from the objects being scanned, and the resolution (density of scanning points at that distance) was varied as I tried to make things work.

At 0.1 mm point spacing, I ran into this problem (gastropod):
snail 0.1mm
Hitting the limit of the resolution causes this weird striping pattern. This might be okay if the surface were accurately represented, but at this point you lose depth perception as well: the scatter on those stripes averages around 9 mm between the front “surface” and the back, meaning that the surface itself (if I modeled this scan) would vary that much. Not so good.

At 1 mm point spacing, things were better but not so great (gastropod):
snail 1mm
The stripes are toned down, but the error is just too large for a decent 3D model to be produced :-(. With 1 mm spacing between points, even if the points were a surface rather than a cloud, this is about the smallest object I would try to scan with it.

Finally, fellow graduate student Ted wanted to try out the Triceratops model. With 1 mm spacing, this is what we got:
rawr
Although I’m sure the morphology is incorrect in the details, such a scan fits in nicely with the current horned dinosaur publishing extravaganza going on.

Final verdict: while the Leica Scanstation is good for some things, scanning small fossils is not one of them.

For Sale: Geological Survey Professional Papers

I’ve had these taking up shelf space for a while, and since I need to pay off some bills, they’re going up for sale on Amazon.com. Prices were chosen based on that site and Alibris, so if anyone has a better idea of what I can charge, let me know. I’m trying to be competitive so I can get these off my hands.

If you wish to buy from me, make sure you’re buying from seller ‘meburt01.’

Geological Survey Professional Paper 213: Gold deposits of the southern Piedmont

Geological Survey Professional Paper 255: Pegmatite investigations, 1942-45, New England

Geological Survey Professional Paper 256: Geology of the San Manuel copper deposit, Arizona

Geological Survey Professional Paper 292: Geology of the southern Elkhorn Mountains, Jefferson and Broadwater Counties, Montana

Geological Survey Professional Paper 419: Miocene Marine Mollusks from the Astoria Formation in Oregon

Geological Survey Professional Paper 420-A: Geology of the Los Angeles Basin California – an Introduction

Geological Survey Professional Paper 420-B: Geology and oil resources of the eastern Puente Hills area, southern California

Geological Survey Professional Paper 421-B: Bedrock geology of the Kassler quadrangle, Colorado

Geological Survey Professional Paper 422-A: Morphology and hydrology of a glacial stream–White River, Mount Rainier, Washington

Off-topic: GoPro Sport Videos

It’s not science, but it could be used for science, if I had to chase down fossils or something. Since that’s not really an option, I’ve been using my GoPro Helmet Hero (the original, non-HD version) to capture some cool things but haven’t had a chance to blog. Here’s a video from END-IT, the Extreme North Dakota Iceman Triathlon, back in March. The disciplines were nordic skiing (doubletrack classic for the most part), cycling (some of it on snowmachine trails), and trail running. Per the END Racing creed, there was a bit of adventure thrown in. At the end we had to sled down a hill and run back up three times.


I ended up getting second overall in this race, which is far beter than how I had expected to do since I’m not a strong nordic skier. If you watch the raw footage, you can actually see where I messed up tactically–since I was wearing a camera on my head, I had to switch mounts twice (once between the ski and cycle legs and then once again between the cycle and run legs). If I hadn’t wasted that time, I may have been able to win overall–but then you wouldn’t have this cool video now, would you?

Since I haven’t posted about this camera before, I’d like to say a few things. I love it for what it lets me do, but it could be designed slightly better. A lot of people complain about battery usage, but I’ve been having success lately with rechargeable NiMH AAs rather than lithiums. It would be great to have more of an indication from behind whether the camera is recording or not, and recording without a date on the files is annoying. Also mentioned by others is the amount of recording you can do at once; I applied this firmware update and haven’t had any problems (it will let you record for twice the normal time in one file and use a larger memory card). I honestly think it’s a great little camera; it’s rugged and waterproof, it records video, it’s fisheye so you can see a lot more, and you can strap it onto yourself in a variety of ways. Thumbs up.

Researching Laser Scanning and Rapid Prototyping of Fossils

This post is a summary of my research over the past few days; I’ll continue to update it or make new posts as necessary.

Introduction
One of the growing subfields of paleontology is the digitization of fossil material via 3D laser scanning. There are several reasons to do this: protecting valuable specimens from potentially destructive handling, making virtual models available for morphometric analysis, and producing physical replicas of specimens, either for sharing with other institutions or for performing physical tests relating to size and shape. Two disparate technologies must come together for all of the above to come to pass: first, a scanning system to accurately digitize specimens (via laser or, in some cases, photography) so that they can be visualized and manipulated on-screen; second, a rapid prototyping system that can accurately reproduce objects with fine detail and accuracy to the original model. I am concurrently researching both of these technologies to determine the options we have at my institution.

Specimens and Detail
The collection at UND comprises mostly invertebrate fossils, and of those a great many are freshwater mussels and gastropods. Generally these objects are a good size to scan and do not have “important” morphological features that are very small; however we currently have two graduate students studying mammals via teeth and one student studying microsnails. These items range to several millimeters, so when it comes to detail we need to be pushing the edges of the technology as much as we can afford, in order to get good data. (I don’t have to worry as much since I’m studying normal-sized mussels, but in paleo as in everything else, the more decimal places, the better.) It would be excellent if we could capture surface features less than 0.1 mm in height.

Laser Scanning
Several systems are available for digitizing physical objects; I am focusing on laser scanning because it can produce virtual models of highly detailed objects that are very accurate to the original. Other methods of creating 3D models are photogrammetry and to a lesser extent morphometric probes that record the position of landmarks in three dimensions but not the intervening surfaces.

Build-your-own scanning systems:

These systems generally utilize a line laser and a webcam to digitize objects, although the Cyclops uses a “shadow line” and the DAVID can use both. The object is digitized by the interpretation of the bright laser line (or dark shadow line) on the image pulled from the webcam: the position of the surface is calculated based on the known relationship between the laser and the camera or the laser and the background. From my rough experience (earlier this summer with DAVID and just today with a hacked version of MakerScanner), it is quite difficult to get a really good scan, although some of the planeless scans done by people on the DAVID forum are amazingly good. If you want a good scan, you can do it, but you’re going to use up a lot of time and effort getting to that point. I will be playing with replicating a MakerScanner some more over the next few days and hope to report on the results.

“Cheap” scanning systems:

Currently, only the NextEngine scanner is priced “cheaply” when it comes to laser scanning. For $2,995 you can get the basic package, and for $995 more you can get even better precision. I’ve seen a lot of commentary on this scanner, and all of it good, but I’m not sure it will capture enough detail for our needs. The “dimensional accuracy” is +-0.0005″, or about 0.0127 mm. That’s pretty darn good, but will it work for us? We’ll have to go visit someone and see. [Polo and Felicísimo found less desirable accuracy: “±0.81 mm and ±1.66 mm”. 2014-04-07]
http://palaeo-electronica.org/2008_2/134/index.html
http://reporting.journalism.ku.edu/fall08/adler-noland/2008/11/ku-geologist-preserves-dinosau.html

Expensive scanning systems:

  • ???

I had a larger list of these systems a couple months back, but since that information is probably out of date by now, I’ll refrain from posting it. Most of the issues I remember running into are: cost (of course), intended use (if they’re designed for reverse engineering, will they work for fossils?), and, well, cost. Now, I’m all for getting the top-of-the-line scanner so you can do the most awesome digital models possible, but paleo is one of those disciplines in which you do what you can with what you have, because the cashflow isn’t always the steadiest. On this note, we do have a Leica Scanstation in the department that I have experience with scanning landscape features; I will be testing it out soon to see how well it can do with closeups on small items.

All in all, more research needs to be done on the available laser scanners to see which is best suited for our purposes. I will be posting as I can talk to people about their experiences.

I’ll leave things there for today and pick up in a little while with the next section: rapid prototyping.

Design and the science and what’s to come

The new Blogger template designer is quite good [As you can see, though, I’m no longer on Blogger.  2014-02-07]. I’m still trying to find something I’m the most happy with, however.

Some changes in content may be coming down if I find the time, but the purpose of this blog will remain the same: documenting ideas I find interesting and recording things I’ve learned that may be useful to others. There will continue to be code snippets and blockquotes from various sources, but I hope to tighten things up and provide a bit more analysis as I go.

Possible topic ideas for the near future*

  • Planning to finish up the project from NAPC last year (freshwater mussel shape change over distance)
  • Experiences with small-scale laser scanning (not only DAVID but MakerScanner, something I just found yesterday)
  • More videos of science in action (including wind tunnel studies and rooftop apparatus)
  • My fascination with trace fossils
  • The total-body experience that is trying to build a useable specimen database
  • Making my thesis code available

Off-topic interests may include

  • Cycling in and around Grand Forks, ND
  • Book reviews not relating to science (but I will try to relate them in some way)
  • Video from various excursions that were more athletic than academia

If anyone has suggestions for other topics, I’m open and ready to discuss things about which I may know more than the average person. Post me a comment and I’ll see what I can do.


*Motiviating myself by telling other people what my plans are. Sometimes it works.