Process scientific multidimensional data.
Project description
Sciproc in experimental stage provides tools to select, edit, convert scientific (observed, model-generated) data. It needs Numpy. It’s very experimental, as some functions aren’t tested or only tested in ‘idealised cases’, so please be careful. Please let me know if you would like to contribute. Currently selection from 1D data by coordinates or certain timestep and applying a function repeatedly on a multidimensional matrix is implemented. However selecting, interpolating and editing procedures for multidimensional data is planned in the near future. You might want to use it if you have have any observational data and you want to select a period, make a selection with a certain timestep or make an interpolation. The aim is to make an addition to the cdo climate data operators with python power (see also pynacolada). It should be working with normal numpy data. However, if you want to process netcdf-files, we recommend to use the pynacolada interface which acutally uses sciproc. Typical usage often looks like this:
#!/usr/bin/env python from numpy import * from sciproc import * # select data from a 1-D array: data = array([1.0,2.0,4.0,2.5]) incoords = array([0.0,1.0,2.0,3.0]) print(datatimeco(data,coords = incoords,outcoords = array([1.0,2.0])) a = array([[[1,3,2],[2,1,3],[4,1,3]],[[1,2,3],[4,1,2],[3,0,1]]]) print('copy') print( multifunc(a,[False,False,True],lambda x: copyfunction(x))) print('take only elements 2 and 3 from third dimension') print(multifunc(a,[False,False,True],lambda x: secondandthirdelement(x))) print('take only elements 2 and 3 from second dimension') print(multifunc(a,[False,True,False],lambda x: secondandthirdelement(x))) print('reduce dimension')
A Section
A Sub-Section
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file sciproc-0.7.23.tar.gz
.
File metadata
- Download URL: sciproc-0.7.23.tar.gz
- Upload date:
- Size: 27.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd9706cf9413a7711c4152d935c8d622e2cf863c3005c92b2ea592cb1a5a8648 |
|
MD5 | 0723240b0971f7ead8394ae7ece4b200 |
|
BLAKE2b-256 | 547cebf051b5adcad0768a0e926e5ee23092c2d9ade3311f7eb9531cf1370138 |