File: python-test

package info (click to toggle)
python-awkward 2.8.10-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 25,140 kB
  • sloc: python: 182,845; cpp: 33,828; sh: 432; makefile: 21; javascript: 8
file content (12 lines) | stat: -rwxr-xr-x 407 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
#!/usr/bin/env python3
# autopkgtest check: Check whether awkward module is importable
# and does basic tasks
# Author: Sascha Steinbiss <satta@debian.org>

import awkward 

array = awkward.Array([[{"x": 1.1, "y": [1]}, {"x": 2.2, "y": [1, 2]}, {"x": 3.3, "y": [1, 2, 3]}], [], [{"x": 4.4, "y": [1, 2, 3, 4]}, {"x": 5.5, "y": [1, 2, 3, 4, 5]}]])

import numpy as np

output = np.square(array["y", ..., 1:])