HNHacker News
TopNewBestAskShowJobs

tylermw

1,012 karma · joined January 8, 2018

https://www.tylermw.com
submissionscomments
tylermw··on Shaded Relief Maps in Blender
Thanks!
tylermw··on Shaded Relief Maps in Blender
For doing this type of work programmatically in R, check out the rayshader package:

https://www.rayshader.com

It has a high-quality pathtracing renderer built-in (https://www.rayrender.net) that only requires a single line of R code to produce results similar to what's offered here (without all the manual work).

tylermw··on What's bad about Julia?
This really isn't a big deal. I switch between C/C++/R all the time and mixing zero/one indexing isn't some huge mental burden or source of intractable bugs--you get used to it after a few days.
tylermw··on Julia Computing raises $24M Series A
While writing in C is one way to speed up R code, you can also get pretty close to compiled speed by writing fully vectorized R code and pre-allocating vectors. The R REPL is just a thin wrapper over a bunch of C functions, and a careful programmer can ensure that allocation and copy operations (the slow bits) are kept to a minimum.
tylermw··on Julia Computing raises $24M Series A
> Julia's DF library is generic and allows user defined ops and types. You can put in GPU vectors, distributed vectors, custom number types etc. Julia optimizes all this stuff.

These features aren't of interest to practicing statisticians, which the parent comment was talking about.

> data.frame is just a giant chunk of c (c++) code that one must interact with in very specific ways

I don't understand this criticism: yes, data.table has an API.

tylermw··on Julia Computing raises $24M Series A
"Massively better performance" is a bit misleading: Julia is only massively better at certain workflows. The fastest data.frame library in ALL interpreted languages is consistently data.table, which is R. For in-memory data analysis, Julia will have to offer more than performance to win over statisticians/researchers.

Benchmarks: https://www.ritchievink.com/blog/2021/02/28/i-wrote-one-of-t...

tylermw··on Julia Computing raises $24M Series A
Once your Rcpp code is compiled, it's almost indistinguishable from base R (when you're calling it). All R functions eventually end up calling R primitives written in C, and Rcpp just simplifies the process of writing and linking C/C++ code into the R interpreter.

The only difficulty with Rcpp-based R packages is you have to ensure the target system can compile the code, which means having a suitable compiler available.

tylermw··on Julia Computing raises $24M Series A
Not much an argument at all, if you ask me. There's definitely a benefit to only having to learn a single language (rather than R and C++), but the library/package ecosystem in R is hard to beat; unless you're doing truly bespoke computational work, the number of mature statistical libraries/packages in R is unmatched. Rcpp's syntactic sugar means most slow R bottlenecks can be written in C++ almost verboten, but without the interpreted performance penalty. One of R's best and under-emphasized features is its straightforward foreign-function interface: it's easy to creating bindings to C/C++/Fortran routines (and Rust support is coming along as well).

I've been impressed with Julia, but it's hard to beat 25 years of package development.

tylermw··on Everything You Might Want to Know about Whaling
I learned more than I ever needed to know about whaling when I decided to read an unabridged version of Moby Dick. The book goes: Plot -> 100 page guide on hunting, killing, and dismembering and processing a whale carcass -> Plot.
tylermw··on MagicaCSG: A lightweight signed distance field editor and renderer
ephtracy (the creator of MagicaVoxel and now MagicaCSG) doesn't open source their tools, as far as I know.
tylermw··on Why American construction costs are so high (2019)
John Stossel really shows his hand in that piece when he uses "wheelchair access" as an example of government spending run amok. Why shouldn't disabled people should be able to access facilities they pay for with their tax dollars? Why is complying with the ADA--a bipartisan law signed by George H.W. Bush--seen as a waste of taxpayer money?
tylermw··on FDA approves first test of CRISPR for genetic defect causing sickle cell disease
No, scientists who are eager to take out mosquitos want to do it because it will save millions of lives. People have been dying of malaria for millennia—climate change has nothing to do with this particular issue/solution.
tylermw··on A Model of the Cosmos in the Ancient Greek Antikythera Mechanism
The data on that USB drive will deteriorate over a couple decades. NAND memory generally isn't an adequate format for archival purposes.
tylermw··on Research software code is likely to remain a tangled mess
> good experiments change a single variable at a time

Although this is a tangent from the above conversation, this isn't actually true: well-designed experiments can indeed change multiple variables at the same time. There's an entire field of statistics dedicated to experimental design (google "factorial designs" for more information). One-factor-at-a-time (OFAT) experiments are often the least efficient method of running experiments, although they are conceptually simple.

See the following article for a discussion: http://www.engr.mun.ca/~llye/czitrom.pdf

tylermw··on On Repl-Driven Programming
I don’t know about MATLAB, but everything you describe is trivial to do in R. Being dropped into the debugger is standard on most R installs (it’s an option you can turn off) and everything you mentioned can be done in the REPL.
tylermw··on Raytracing in One Weekend (2016)
What snake oil is being sold here with a free book? Who exactly is a hack? Sure, there's some technical differences between the two terms, but outside of the research community they are used interchangeably.
tylermw··on Raytracing in One Weekend (2016)
This book series is great—I built an entire pathtracer in R (rayrender)* following this series. I'd recommend reading these books and then reading Matt Pharr's "Physically Based Rendering", also available for free online (http://www.pbr-book.org). Starting with a pathtracer based on Peter's book and then slowly integrating elements of PBRT (the pathtracer featured in PBR) as needed has been a great pedagogical exercise: RTIOW teaches using a bottom-up approach, while PBR very top-down. If you've written the pathtracer described in RTIOW, you end up with a much fuller understanding of many of the choices made in PBRT.

Also, PBR is getting a fourth edition this year that goes into fully GPU rendering—it's a great time to start learning about pathtracing!

*Rayrender Github: https://www.github.com/tylermorganwall/rayrender

Website/Docs: https://www.rayrender.net

tylermw··on I Am Deleting the Blog
Really enjoyed reading this level headed discussion, thank you
tylermw··on Ray Tracing Essentials Part 7: Denoising for Ray Tracing
The main benefit of raytracing is primarily for the CG artist pipeline/workflow. Complex, realistic lighting effects just drop out of the integrator, and changing scene lighting is much more akin to a lighting director on a movie set. Whereas with rasterization an 3D artist has to know the correct hack (i.e. "smart technique") to use in each situation--along with the failure modes for that hack.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Thanks! For your question, check out Open Drone Map, which is an open source toolkit for doing just that:

https://www.opendronemap.org

I also provide instructions in my (free and open source!) masterclass on how to take LIDAR data from cities and build 3D surface models that includes buildings:

Github Course Materials:

https://github.com/tylermorganwall/MusaMasterclass

tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
You can also query elevation tiles using the `elevatr` package and use them in a similar way.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Good to know, thanks! I'll add a note mentioning the need for an account.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
It looks like they're a firm that does large-scale photogrammetry to build 3D models worldwide--this is just a tutorial on how to combine existing topographic datasets (e.g SRTM or a USGS elevation product) with satellite imagery to generate small-scale 3D maps in R. Similar in concept, vastly different in scale and execution
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Thanks! I always enjoy when a library has a solid README with examples, especially when it's a visualization library. Wanted to make sure I had one myself.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Related: in my masterclass (free and open source, materials here: https://github.com/tylermorganwall/MusaMasterclass) I also walk through how you can convert LIDAR data into hi-res DEMs to generate 2D and 3D maps
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
The R GIS ecosystem has seen great strides recently! I've just been working on one part of it: 3D visualization and computational hillshading/raytracing.

And that video looks like a great resource--I'll put it on my watch list.

tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
No color support, but you can export the map to an STL file with the function `save_3dprint()`. You can declare the maximum width/depth and it will scale the model to the size you've specified.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Additionally, the `elevatr` package (https://github.com/jhollist/elevatr) serves tiles directly from AWS Open Data Terrain Tiles. I don't believe it requires a key.
tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Mapbox has an API you can query from--I believe they have a free tier. The `ceramic` package makes this easy to pull from, but you need to get a Mapbox key first:

https://github.com/hypertidy/ceramic

tylermw··on Guide to Making 3D Maps with Satellite Imagery in R
Author here, I wrote this to show how you can use the rayshader package to generate 3D maps in R using free and open data (in this case, Landsat 8 imagery and SRTM elevation data). You can check out rayshader's Github repo here:

Github: https://www.github.com/tylermorganwall/rayshader

And browse the documentation (with rendered examples) and README on its website: https://www.rayshader.com

← PreviousPage 3 of 6Next →