

Using PLA Wood, from Hatchbox.


Using PLA Wood, from Hatchbox.
Meshlab can do this, if you don't have access to a linux machine and use
ctmconv red-rocks-smrf-only-delaunay.ply red-rocks-smrf-only-delaunay.ply
Meshlab seems great, may even be as useful as Blender.
On Windows 10, the default viewer.
I'm going to use the Creality Slicer (which is based off Cura). It doesn't quite fit.
This seems reasonable to print.
Will fire up the printer and see!
Using Blender, I add a cube and played around with the positioning. I found the Blender UI to be very non-intuitive.
Then export as PLY file. It looks like this.
Looking at Red Rocks.
# This is a hjson file, https://hjson.org/
# Linux bash
#GET=https://github.com/hjson/hjson-go/releases/download/v3.0.0/linux_amd64.tar.gz
# macOS bash
#GET=https://github.com/hjson/hjson-go/releases/download/v3.0.0/darwin_amd64.tar.gz
# Install
#curl -sSL $GET | sudo tar -xz -C /usr/local/bin
# Translate to Json
#hjson -j pipeline.hjson > pipeline.json
#pdal pipeline pipeline.json --verbose 8
{
pipeline:
[
# Input
{
# read from our ept server
# up to 0.5m resolutions
# type: readers.ept
# bounds: ([802000, 802500], [2493000, 2493500])
# filename: http://localhost:8080/ept.json
filename: red-rocks.laz
# filename: http://na.entwine.io/red-rocks/ept.json
# resolution: 0.5
}
# {
# # read from our las file
# type: readers.las
# filename: small500-no-outliers.laz
# }
# Filters
{
# adds a classification value of 7 to the noise points
type: filters.outlier
# method: radius
# radius: 1.0
# min_k: 8 # min number of neighbors in radius
method: statistical
mean_k: 8
multiplier: 3
}
{
# voxel-based sampling filter
# reduce the size of the pc
# cell size of 0.2 meters in xyz
type: filters.voxelcenternearestneighbor
cell: 0.1
}
{
# Need to assign point cloud dimension NumberOfReturns 1
# Otherwise: "No returns to process."
type:filters.assign
assignment : NumberOfReturns[0:0]=1
}
{
# Ground classification, ignore the noise points
type: filters.smrf
ignore:Classification[7:7]
}
{
# only allow ground classified points
type: filters.range
limits: Classification[2:2]
}
{
# OPTIONAL
# turn this into a DEM 3D model
# do not use multiple types
# type: filters.delaunay
type: filters.poisson
}
# Output
# # OPTIONAL PLY IF DEM
{
# write to ply
type:writers.ply
filename: red-rocks-smrf-only-poisson.ply
faces:true
storage_mode: default
}
# Output
# {
# # write to laz
# type:writers.las
# filename: red-rocks-ground.laz
# }
]
}
https://gist.github.com/sunapi386/9a9ece302d646ee80a72fc494423a633
To go a little more "detailed", I put depth to 12. The file went from 84M to 789M. And it is definitely overkill for 3D printing.
Program failed to compute the grid projection.
pdal pipeline dtm-gdal.json --verbose 8
(PDAL Debug) Debugging...
(pdal pipeline Debug) Attempting to load plugin '/usr/local/lib/libpdal_plugin_filter_gridprojection.so'.
(pdal pipeline Debug) Loaded plugin '/usr/local/lib/libpdal_plugin_filter_gridprojection.so'.
(pdal pipeline Debug) Initialized plugin '/usr/local/lib/libpdal_plugin_filter_gridprojection.so'.
(pdal pipeline readers.las Debug) GDAL debug: OGRSpatialReference::Validate: No root pointer.
(pdal pipeline readers.las Debug) GDAL debug: OGRSpatialReference::Validate: No root pointer.
(pdal pipeline readers.las Debug) GDAL debug: OGRSpatialReference::Validate: No root pointer.
(pdal pipeline Debug) Executing pipeline in standard mode.
(pdal pipeline filters.gridprojection Debug) Process GridProjectionFilter...
[pcl::GridProjection::getBoundingBox] Size of Bounding Box is 1
[pcl::GridProjection::getBoundingBox] Lower left point is [-2.500000, -2.500000, -2.500000]
[pcl::GridProjection::getBoundingBox] Upper left point is 2
[pcl::GridProjection::getBoundingBox] Padding size: 3
[pcl::GridProjection::getBoundingBox] Leaf size: 0.500000
(pdal pipeline filters.gridprojection Debug) 3141373 before, 180 after
(pdal pipeline filters.gridprojection Debug) 180
double free or corruption (!prev)
fish: “pdal pipeline dtm-gdal.json --v…” terminated by signal SIGABRT (Abort)
Cura can take STL inputs. Converting the PLY into STL is simple.
sudo apt install openctm-tools
Then ctmconv red-rocks-smrf-only-delaunay.ply red-rocks-smrf-only-delaunay.stl
can convert ply to stl
ctmviewer red-rocks-smrf-only-delaunay.ply
visualizes the ply. Which is what I used above.
Looks like the Poisson is prettier.
I'll continue writing this latter, until I have something printed. 🙂
https://pdal.io/stages/filters.voxelcenternearestneighbor.html#filters-voxelcenternearestneighbor
The VoxelCenterNearestNeighbor filter is a voxel-based sampling filter. The input point cloud is divided into 3D voxels at the given cell size. For each populated voxel, the coordinates of the voxel center are used as the query point in a 3D nearest neighbor search. The nearest neighbor is then added to the output point cloud, along with any existing dimensions.
Notice the red dots are much more sparse than the gray intensity dots. Red dots are separated 1.0 meters and gray are 0.1 meters.
To generate this I did converted with PDAL and then used Potree to visualize.
pdal pipeline $HOME/voxcnn-1.0.json
voxcnn-1.0.json
[
"801403-802580-2493384-2494335.laz",
{
"type":"filters.voxelcenternearestneighbor",
"cell":1.0
},
"801403-802580-2493384-2494335-voxelcenternearestneighbor-1.0.laz"
]
-rw-rw-r-- 1 jsun jsun 65M Apr 11 21:01 801403-802580-2493384-2494335-voxelcenternearestneighbor.laz
-rw-rw-r-- 1 jsun jsun 8.1M Apr 11 21:04 801403-802580-2493384-2494335-voxelcenternearestneighbor-1.0.laz
Airbnb already pays occupancy taxes for you so you can deduct them as a rent expense.
I run an Airbnb in Maine and they send occupancy taxes to the state. How do I show my Airbnb income as exempt since the tax has already been paid?
Asked by jlouisecarl
TurboTax Premier
2 months ago
Occupancy taxes for your Airbnb are a completely separate tax from your income tax that you are filing. Having paid the occupancy tax through Airbnb does not make your income exempt from income tax. All of the rent collected must still be reported as income. However, you will be able to claim a rental expense for the occupancy tax that has been paid on your behalf since it was taken out of your rental income.
TurboTaxAnnetteB , EA
TurboTax TaxPro 2 months ago
The setup
I have 2 network adapters, a 10G and a 1G network. In order to connect to both networks, you must have two profiles.
If you have a single profile, then changing settings for one network adapter will also affect the other. In Ubuntu's Network UI, this is non-obvious.
Once setup correctly, you can verify by being able to ping both networks.
jsun@computer ~ [1]> ping 192.168.1.200
PING 192.168.1.200 (192.168.1.200) 56(84) bytes of data.
64 bytes from 192.168.1.200: icmp_seq=1 ttl=128 time=0.338 ms
64 bytes from 192.168.1.200: icmp_seq=2 ttl=128 time=0.172 ms
^C
--- 192.168.1.200 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1028ms
rtt min/avg/max/mdev = 0.172/0.255/0.338/0.083 ms
jsun@computer ~> ping 10.10.50.1
PING 10.10.50.1 (10.10.50.1) 56(84) bytes of data.
64 bytes from 10.10.50.1: icmp_seq=1 ttl=64 time=0.585 ms
64 bytes from 10.10.50.1: icmp_seq=2 ttl=64 time=0.226 ms
^C
--- 10.10.50.1 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1022ms
rtt min/avg/max/mdev = 0.226/0.405/0.585/0.180 ms
An octree is a tree data structure in which each internal node has exactly eight children. Octrees are most often used to partition a three-dimensional space by recursively subdividing it into eight octants. Octrees are the three-dimensional analog of quadtrees.
We humans mostly deal with low dimensional data, so we give this type of structure some names:
These are all tree-like data structures, which are very useful for range and nearest neighbor searches.
Space filling curves refers to a class of functions that k dimensional data to 1 dimension.
Meaning a class of functions that can map k-dimensional data into a single number n
f(n_1, n_2, ..., n_k) -> n
The caveat is there is a restriction on the number it maps, i.e. n_1, as space filling curves are a fractal functions, it cannot be extended to the reals, but rather to the binary fractions (a subset of the rationals). This lets you get arbitrarily close to any number you want (and cover all the IEEE floating points).
There are certain optimal use cases for each of these.
There are some variants on structures for storing multi-dimensional data.
It's yet another type of tree.
I won't go in too much detail because this is out of scope, but in programming there are databases and data stores which can handle large amount of high dimensional data.
First, a distinction. A database can handle complex queries. A data store can be dumber, simple storage format and won't handle things like transaction for you.
An analogy could be like "database is like an accountant, who you can ask for certain data and operations, such as 'give me all last year's data for people with last names in T'", whereas "data store is like a library and you have to go find and collect that data yourself, but it's stored in an organized fashion".
root@computer ~# lsblk -f sda ├─sda1 vfat 7F3B-9703 /boot/efi ├─sda2 ext2 b6220db2-916c-4322-b64b-c86769f6b18b /boot └─sda3 crypto_LUKS 3a07b8a9-3e75-41a9-88d4-3be937181613 └─luks-3a07b8a9-3e75-41a9-88d4-3be937181613 LVM2_member uCvHaW-RlQc-PT2d-cBg2-SWyY-WS0A-ZCEvA6 ├─ubuntu--vg-root ext4 a78662e2-d582-4faa-88b6-b6db5e23aed2 / └─ubuntu--vg-swap_1 swap 5c4ba6cc-4735-4417-9e87-74a76a7fc415 [SWAP] sdb ├─sdb1 vfat 1EC8-1F58 ├─sdb2 ext2 7108fe1d-dc37-4213-a3bc-8070a8f84f31 /media/jsun/7108fe1d-dc37-4213-a3bc-8070a8f84f31 └─sdb3 crypto_LUKS fc560468-588c-4455-af2c-295998c41c88
We see that sdb3
is the unmounted target.
root@computer ~# udisksctl unlock -b /dev/sdb3
Passphrase:
Unlocked /dev/sdb3 as /dev/dm-3.
See which one is the new unlocked
root@computer ~# ls -la /dev/mapper/ | grep dm-3
lrwxrwxrwx 1 root root 7 Mar 22 17:32 luks-fc560468-588c-4455-af2c-295998c41c88 -> ../dm-3
luks-fc560468-588c-4455-af2c-295998c41c88
is our target. Let's remember that with a variable.
set target luks-fc560468-588c-4455-af2c-295998c41c88
The VG Name
of both drives is the same; this is problematic and will prevent you from being able to mount the drives both at the same time.
root@computer ~# pvdisplay
--- Physical volume ---
PV Name /dev/mapper/luks-3a07b8a9-3e75-41a9-88d4-3be937181613
VG Name ubuntu-vg PV Size 930.53 GiB / not usable 2.00 MiB
Allocatable yes (but full)
PE Size 4.00 MiB
Total PE 238216
Free PE 0
Allocated PE 238216
PV UUID uCvHaW-RlQc-PT2d-cBg2-SWyY-WS0A-ZCEvA6
--- Physical volume ---
PV Name /dev/mapper/luks-fc560468-588c-4455-af2c-295998c41c88
VG Name ubuntu-vg
PV Size 930.53 GiB / not usable 2.00 MiB
Allocatable yes (but full)
PE Size 4.00 MiB
Total PE 238216
Free PE 0
Allocated PE 238216
PV UUID lbvecI-E6w6-fpuj-P61G-5NCb-obOK-ooivpe
root@computer ~# uuidgen
1ec80451-b05b-4d59-94c1-f1ad70b24255
root@computer ~# vgrename $uuid 1ec80451-b05b-4d59-94c1-f1ad70b24255
Processing VG ubuntu-vg because of matching UUID TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
Volume group "TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v" successfully renamed to "1ec80451-b05b-4d59-94c1-f1ad70b24255"
root@computer ~# pvs -o +vg_uuid
PV VG Fmt Attr PSize PFree VG UUID
/dev/mapper/luks-3a07b8a9-3e75-41a9-88d4-3be937181613 ubuntu-vg lvm2 a-- 930.53g 0 TAva2M-zNnV-Wh5h-3YcY-Vc5U-W4se-TI27Du
/dev/mapper/luks-fc560468-588c-4455-af2c-295998c41c88 1ec80451-b05b-4d59-94c1-f1ad70b24255 lvm2 a-- 930.53g 0 TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
The device UUID is TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
. Let's remember that with a variable.
set uuid TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
I'm going to generate a UUID, but you can name whatever you want.
root@computer ~# uuidgen
1ec80451-b05b-4d59-94c1-f1ad70b24255
root@computer ~# vgrename $uuid 1ec80451-b05b-4d59-94c1-f1ad70b24255
Processing VG ubuntu-vg because of matching UUID TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
Volume group "TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v" successfully renamed to "1ec80451-b05b-4d59-94c1-f1ad70b24255"
root@computer ~# pvs -o +vg_uuid
PV VG Fmt Attr PSize PFree VG UUID
/dev/mapper/luks-3a07b8a9-3e75-41a9-88d4-3be937181613 ubuntu-vg lvm2 a-- 930.53g 0 TAva2M-zNnV-Wh5h-3YcY-Vc5U-W4se-TI27Du
/dev/mapper/luks-fc560468-588c-4455-af2c-295998c41c88 1ec80451-b05b-4d59-94c1-f1ad70b24255 lvm2 a-- 930.53g 0 TJgeFw-xDcf-TaJ2-07dL-RlUQ-yCsb-zGGp4v
Check/notice the new volume group name 1ec80451-b05b-4d59-94c1-f1ad70b24255
.
root@computer ~# vgchange -a y
2 logical volume(s) in volume group "ubuntu-vg" now active
2 logical volume(s) in volume group "1ec80451-b05b-4d59-94c1-f1ad70b24255" now active
Remember to rename your volume group back to ubuntu-vg
if you want the volume to still be bootable.
root@computer ~# mkdir /media/badboy
root@computer ~# mount /dev/1ec80451-b05b-4d59-94c1-f1ad70b24255/root /media/badboy
root@computer ~# cd /media/badboy/
root@computer /m/badboy# ls
bin/ cdrom/ etc/ initrd.img@ lib/ lib64/ media/ opt/ root/ sbin/ srv/ tmp/ var/
boot/ dev/ home/ initrd.img.old@ lib32/ lost+found/ mnt/ proc/ run/ snap/ sys/ usr/ vmlinuz@
You can now access your data.