EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: pyepics: Strategies for working with fast-changing large arrays
From: Andrew Johnson <[email protected]>
To: [email protected], Anton Derbenev <[email protected]>
Date: Wed, 11 Jan 2012 11:30:00 -0600
Hi Anton,

On 2012-01-11 Anton Derbenev wrote:
> When I add a callback for a PV object with array
>  data within, I become "subscribed" to the entire array. The problem may be
>  that, as described below, the PV image data is always seen as large as (in
>  my case) 1228800 elements array, while the actual region of interest size
>  can be much smaller (all irrelevant elements of the array simply being set
>  to 0). So, is it possible to create the PV object and the callback for it
>  that will only monitor the specified part of itself (like, I assume,
>  camonitor -# does)?

Assuming that you're using EPICS Base version 3.14.12.1 or later the 
underlying CA library and IOC server do support variable length arrays, but I 
don't know if or how pyepics handles them.  When calling the underlying CA 
library directly from C code if you request an array of zero elements in a 
get-callback or monitor request, you'll get sent the number of elements that 
currently appear in the IOC's array field with no zero padding added.  This 
approach is what the camonitor program uses, and if pyepics supports it you'll 
want to use this feature for maximum throughput of array data.

Note that cainfo reports the size of the storage allocated for the array on 
the IOC, which is the maximum size the array can be.  It can't tell you how 
much data the array currently holds.

HTH,

- Andrew
-- 
Optimization is the process of taking something that works and
replacing it with something that almost works, but costs less.
-- Roger Needham

Replies:
Re: pyepics: Strategies for working with fast-changing large arrays Matt Newville
RE: Strategies for working with fast-changing large arrays michael.abbott
References:
Re: pyepics: Strategies for working with fast-changing large arrays Anton Derbenev

Navigate by Date:
Prev: porting strategy from IDL Paul Sichta
Next: Re: Any CAMAC users left? Sonya Hoobler
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: RE: pyepics: Strategies for working with fast-changing large arrays Mark Rivers
Next: Re: pyepics: Strategies for working with fast-changing large arrays Matt Newville
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  <20122013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 18 Nov 2013 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·