Skip to content

Commit 784c94f

Browse files
committed
More files.
1 parent 784be48 commit 784c94f

10 files changed

+123
-2
lines changed

pdal/test/data/from-module.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"pipeline":[
3-
"./1.2-with-color.las",
3+
"./pdal/test/data/1.2-with-color.las",
44
{
55
"type": "filters.python",
6-
"script": "./test1.py",
6+
"script": "./pdal/test/data/test1.py",
77
"module": "anything",
88
"function": "fff"
99
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/las/1.2-with-color.las",
4+
{
5+
"type":"filters.crop",
6+
"polygon":"POLYGON ((636889.4129512392682955 851528.5122932585654780, 636899.1423342394409701 851475.0006867571501061, 636899.1423342394409701 851475.0006867571501061, 636928.3304832403082401 851494.4594527576118708, 636928.3304832403082401 851494.4594527576118708, 636928.3304832403082401 851494.4594527576118708, 636976.9773982415208593 851513.9182187581900507, 636976.9773982415208593 851513.9182187581900507, 637069.4065367440925911 851475.0006867571501061, 637132.6475262457970530 851445.8125377562828362, 637132.6475262457970530 851445.8125377562828362, 637336.9645692512858659 851411.7596972554456443, 637336.9645692512858659 851411.7596972554456443, 637473.1759312548674643 851158.7957392486277968, 637589.9285272579872981 850711.2441212366102263, 637244.5354307487141341 850511.7917697312077507, 636758.0662807356566191 850667.4618977354839444, 636539.1551632297923788 851056.6372177458833903, 636889.4129512392682955 851528.5122932585654780))",
7+
"outside":true
8+
},
9+
{
10+
"filename":"/Users/acbell/pdal/test/temp/autzen-colorized-1.2.3-hole.las",
11+
"compression":false
12+
}
13+
]
14+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/las/1.2-with-color.las",
4+
{
5+
"type":"filters.crop",
6+
"polygon":"POLYGON ((636889.4129512392682955 851528.5122932585654780, 636899.1423342394409701 851475.0006867571501061, 636899.1423342394409701 851475.0006867571501061, 636928.3304832403082401 851494.4594527576118708, 636928.3304832403082401 851494.4594527576118708, 636928.3304832403082401 851494.4594527576118708, 636976.9773982415208593 851513.9182187581900507, 636976.9773982415208593 851513.9182187581900507, 637069.4065367440925911 851475.0006867571501061, 637132.6475262457970530 851445.8125377562828362, 637132.6475262457970530 851445.8125377562828362, 637336.9645692512858659 851411.7596972554456443, 637336.9645692512858659 851411.7596972554456443, 637473.1759312548674643 851158.7957392486277968, 637589.9285272579872981 850711.2441212366102263, 637244.5354307487141341 850511.7917697312077507, 636758.0662807356566191 850667.4618977354839444, 636539.1551632297923788 851056.6372177458833903, 636889.4129512392682955 851528.5122932585654780))",
7+
"outside":false
8+
},
9+
{
10+
"type":"filters.python",
11+
"function":"filter",
12+
"source":"import numpy as np\n\ndef filter(ins,outs):\n\tcls = ins['Classification']\n\n\tkeep_classes = [1,2]\n\n\t# Use the first test for our base array.\n\tkeep = np.equal(cls, keep_classes[0])\n\n\t# For 1:n, test each predicate and join back\n\t# to our existing predicate array\n\tfor k in range(1,len(keep_classes)):\n\t\tt = np.equal(cls, keep_classes[k])\n\t\tkeep = keep + t\n\n\touts['Mask'] = keep\n\treturn True",
13+
"module":"anything"
14+
},
15+
{
16+
"filename":"/Users/acbell/pdal/test/temp/crop-wkt-2d-classification.las",
17+
"compression":false
18+
}
19+
]
20+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/las/1.2-with-color.las",
4+
{
5+
"type": "filters.python",
6+
"script": "/Users/acbell/pdal/test/data/plang/test1.py",
7+
"module": "anything",
8+
"function": "fff"
9+
}
10+
]
11+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/las/1.2-with-color.las",
4+
{
5+
"type":"filters.python",
6+
"module":"anything",
7+
"function":"fff",
8+
"source":"import numpy as np\ndef fff(ins,outs):\n\tX = ins['X']\n\tResult = np.equal(X, 637501.67)\n\t#print X\n\t#print Mask\n\touts['Mask'] = Result\n\treturn True"
9+
}
10+
]
11+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/autzen/autzen.las",
4+
{
5+
"type":"filters.python",
6+
"module":"anything",
7+
"function":"filter",
8+
"source":"import numpy as np\n\ndef filter(ins,outs):\n\tcls = ins['Classification']\n\n\tkeep_classes = [1,2]\n\n\t# Use the first test for our base array.\n\tkeep = np.equal(cls, keep_classes[0])\n\n\t# For 1:n, test each predicate and join back\n\t# to our existing predicate array\n\tfor k in range(1,len(keep_classes)):\n\t\tt = np.equal(cls, keep_classes[k])\n\t\tkeep = keep + t\n\n\touts['Mask'] = keep\n\treturn True"
9+
},
10+
"/Users/acbell/pdal/test/temp/out2.las"
11+
]
12+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/autzen/autzen.las",
4+
{
5+
"type":"filters.stats"
6+
},
7+
{
8+
"type":"filters.python",
9+
"module":"anything",
10+
"function":"filter",
11+
"source":"import numpy as np\n\ndef filter(ins,outs):\n\tret = ins['ReturnNumber']\n\tret_no = ins['NumberOfReturns']\n\n\t# Use the first test for our base array.\n\trets = np.equal(ret, ret_no)\n\n\touts['Mask'] = rets\n\treturn True"
12+
},
13+
"/Users/acbell/pdal/test/temp/out2.las"
14+
]
15+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/autzen/autzen.las",
4+
{
5+
"type":"filters.python",
6+
"module":"anything",
7+
"function":"filter",
8+
"source":"import numpy as np\n\ndef filter(ins,outs):\n\tret = ins['ReturnNumber']\n\n\tkeep_ret = [0, 1,2]\n\n\t# Use the first test for our base array.\n\tkeep = np.equal(ret, keep_ret[0])\n\n\t# For 1:n, test each predicate and join back\n\t# to our existing predicate array\n\tfor k in range(1, len(keep_ret)):\n\t\tt = np.equal(ret, keep_ret[k])\n\t\tkeep = keep + t\n\n\touts['Mask'] = keep\n\treturn True"
9+
},
10+
"/Users/acbell/pdal/test/temp/out2.las"
11+
]
12+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"pipeline":[
3+
"/Users/acbell/pdal/test/data/autzen/autzen-utm.las",
4+
{
5+
"type":"filters.python",
6+
"function":"myfunc",
7+
"module":"derive",
8+
"source":"import numpy as np\ndef myfunc(ins,outs):\n\tX = ins['Y']\n\tX1 = np.zeros(X.size, dtype=type(X[0])) + 314\n\touts['Y'] = X1\n\treturn True"
9+
}
10+
]
11+
}

pdal/test/pipeline/reproject.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"pipeline":[
3+
{
4+
"filename":"/Users/acbell/pdal/test/data/las/1.2-with-color.las",
5+
"spatialreference":"EPSG:2993"
6+
},
7+
{
8+
"type":"filters.python",
9+
"function":"filter",
10+
"source":"import numpy as np\n\ndef filter(ins,outs):\n\tcls = ins['Classification']\n\n\tkeep_classes = [1]\n\n\t# Use the first test for our base array.\n\tkeep = np.equal(cls, keep_classes[0])\n\n\t# For 1:n, test each predicate and join back\n\t# to our existing predicate array\n\tfor k in range(1,len(keep_classes)):\n\t\tt = np.equal(cls, keep_classes[k])\n\t\tkeep = keep + t\n\n\touts['Mask'] = keep\n\treturn True",
11+
"module":"anything"
12+
},
13+
"/Users/acbell/pdal/test/temp/out2.las"
14+
]
15+
}

0 commit comments

Comments
 (0)