#12 closed defect (fixed)
set_quantity API
Reported by: | ole | Owned by: | ole |
---|---|---|---|
Priority: | normal | Milestone: | ANUGA maintenance |
Component: | Architecture and API | Version: | |
Severity: | normal | Keywords: | |
Cc: |
Description (last modified by )
Suggestion for set_quantity
set_quantity(name, X, location, region) where name: Name of quantity X:
-Compatible list, -compatible list or numeric array, -constant -list of points or array with attribute values (use LS) (How to distinguish this from a numeric array? - perhaps use keyword arguments for everything) -callable object (f: x, y -> z) where x,y,z are arrays
- inline
- file functions
- polygon functions -another quantity Q or an expression of the form
a*Q+b*R+c, where a,b,c are scalars, arrays or quantities
Q,R are quantities (or 1?)
- pts filename (use LS and caching) (how to select attribute?)
- general expression to be parsed
location: Where values are to be stored.
Permissible options are: vertices, edges, centroid, unique_vertices
region: Identify subset of triangles. Permissible values are
- tag name (refers to tagged region)
- indices (refers to specific triangles)
- polygon (identifies region)
(incorporate uniqueness/non-uniqueness)
IDEA for set_quantity:
Use keywords and call underlying specific method, e.g.
if filename is not None:
vertex_values = caching( fitfunc, filename, dependencies = ...) set_quantity(..., ..., vertex_values)
elif:
Largely done. Should create class Point_set representing points and attribute(s) Include filename too? Yep (and selected attributes) This could also facilitate use of multiple point sources (e.g. at different resolutions)
Change History (5)
comment:1 Changed 20 years ago by
Status: | new → assigned |
---|
comment:2 Changed 20 years ago by
Description: | modified (diff) |
---|
comment:3 Changed 20 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:4 Changed 20 years ago by
Component: | Compilation and installation → Architecture and API |
---|
comment:5 Changed 19 years ago by
Milestone: | Pyvolution API finished → Pyvolution API maintenance |
---|