getdata-commits Mailing List for GetData (Page 5)
Scientific Database Format
Brought to you by:
ketiltrout
This list is closed, nobody may subscribe to it.
2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(5) |
Oct
(20) |
Nov
(21) |
Dec
(16) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2011 |
Jan
(1) |
Feb
(1) |
Mar
(56) |
Apr
(20) |
May
(4) |
Jun
(2) |
Jul
(3) |
Aug
(11) |
Sep
(2) |
Oct
(4) |
Nov
(18) |
Dec
(16) |
2012 |
Jan
(8) |
Feb
(12) |
Mar
(30) |
Apr
(13) |
May
(10) |
Jun
(17) |
Jul
(18) |
Aug
(19) |
Sep
|
Oct
(1) |
Nov
(1) |
Dec
(9) |
2013 |
Jan
(1) |
Feb
(4) |
Mar
(27) |
Apr
(6) |
May
(3) |
Jun
(1) |
Jul
(10) |
Aug
|
Sep
(3) |
Oct
(15) |
Nov
(4) |
Dec
(9) |
2014 |
Jan
|
Feb
(3) |
Mar
(4) |
Apr
(10) |
May
(15) |
Jun
|
Jul
(14) |
Aug
|
Sep
(2) |
Oct
(6) |
Nov
|
Dec
(9) |
2015 |
Jan
(2) |
Feb
(3) |
Mar
(1) |
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <ket...@us...> - 2013-09-05 22:34:17
|
Revision: 846 http://sourceforge.net/p/getdata/code/846 Author: ketiltrout Date: 2013-09-05 22:34:14 +0000 (Thu, 05 Sep 2013) Log Message: ----------- GetData-0.8.5. Modified Paths: -------------- trunk/html/download.html.in trunk/html/index.html.in Modified: trunk/html/download.html.in =================================================================== --- trunk/html/download.html.in 2013-09-05 22:19:29 UTC (rev 845) +++ trunk/html/download.html.in 2013-09-05 22:34:14 UTC (rev 846) @@ -21,17 +21,17 @@ <h2><a name="source">Latest Release</a></h2> <p>The complete source code for official releases of the GetData project are available from SourceForge. The latest version of GetData, released - 14 May, 2013, is: + 5 September, 2013, is: <ul> <li><a - href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/" - >0.8.4</a>. Four packages are available: + href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/" + >0.8.5</a>. Four packages are available: <dl> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata-0.8.4.tar.bz2/download">getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata-0.8.4.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/getdata-0.8.5.tar.bz2/download">getdata-0.8.5.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/getdata-0.8.5.tar.gz/download">.gz</a>:</dt> <dd>The full source code to the library, with bindings. This package uses the GNU autotools build system, and is designed for POSIX systems (UNIX, Linux, BSD, MacOS X, Cygwin, MSys, &c.)</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata_win-0.8.4.zip/download">getdata_win-0.8.4.zip</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/getdata_win-0.8.5.zip/download">getdata_win-0.8.5.zip</a>:</dt> <dd>A reduced source code package, with the CMake build system designed to be built on Microsoft Windows, either using the free MinGW compiler, or else Microsoft's Visual C++ compiler. (The full source @@ -41,14 +41,14 @@ compressed dirfiles, the Legacy API, and a few other features. This build is used in native Microsoft Windows builds of <a href="http://kst.kde.org/">kst-2</a>.</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/idl_getdata-0.8.4.tar.bz2/download">idl_getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/idl_getdata-0.8.4.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/idl_getdata-0.8.5.tar.bz2/download">idl_getdata-0.8.5.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/idl_getdata-0.8.5.tar.gz/download">.gz</a>:</dt> <dd>The Interactive Data Language (IDL) bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, <a href="#distro">pre-built packages</a> rarely come with these bindings, and this package allows end-users to add support for IDL without having to recompile the whole GetData package.</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/matlab_getdata-0.8.4.tar.bz2/download">matlab_getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/matlab_getdata-0.8.4.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/matlab_getdata-0.8.5.tar.bz2/download">matlab_getdata-0.8.5.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/matlab_getdata-0.8.5.tar.gz/download">.gz</a>:</dt> <dd>The MATLAB bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, <a href="#distro">pre-built @@ -137,7 +137,7 @@ <ul> <li><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/" - >0.8.3</a>—<i>March 2013</i> + >0.8.4</a>—<i>May 2013</i> <li><a href="http://sourceforge.net/projects/getdata/files/getdata/0.7.3/" >0.7.3</a>—<i>April 2011</i> Modified: trunk/html/index.html.in =================================================================== --- trunk/html/index.html.in 2013-09-05 22:19:29 UTC (rev 845) +++ trunk/html/index.html.in 2013-09-05 22:34:14 UTC (rev 846) @@ -59,9 +59,9 @@ <p>The complete source code for official releases of the GetData project are available from SourceForge. <ul><li> - The latest version of GetData, released 14 May, 2013, is <a - href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/" - >GetData 0.8.4</a>.</ul> + The latest version of GetData, released 5 September, 2013, is <a + href="http://sourceforge.net/projects/getdata/files/getdata/0.8.5/" + >GetData 0.8.5</a>.</ul> See: <ul><li><a href="download.html">Get GetData</a></ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-09-05 22:19:33
|
Revision: 845 http://sourceforge.net/p/getdata/code/845 Author: ketiltrout Date: 2013-09-05 22:19:29 +0000 (Thu, 05 Sep 2013) Log Message: ----------- GetData-0.8.5. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/NEWS trunk/getdata/m4/version.m4 trunk/getdata/src/zzslim.c Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-07-29 16:10:17 UTC (rev 844) +++ trunk/getdata/ChangeLog 2013-09-05 22:19:29 UTC (rev 845) @@ -1,3 +1,16 @@ +2013-09-05 D. V. Wiebe <ge...@ke...> svn:845 + GetData-0.8.5 released. + + * src/zzslim.c: + +2013-07-17 D. V. Wiebe <ge...@ke...> svn:835 + + * bindings/python/pydirfile.c: Remove spurious debug printf. + + * bindings/doc/Makefile.am: Fix make clean + + * bindings/bindings/perl/Makefile.am: Fix make clean + 2013-05-14 D. V. Wiebe <ge...@ke...> svn:832 GetData-0.8.4 released. Modified: trunk/getdata/NEWS =================================================================== --- trunk/getdata/NEWS 2013-07-29 16:10:17 UTC (rev 844) +++ trunk/getdata/NEWS 2013-09-05 22:19:29 UTC (rev 845) @@ -1,5 +1,20 @@ -New in version 0.8.4rc2: +New in verison 0.8.5: + Library Changes: + + * The zzslim encoding framework, which was inadvertantly rendered + non-compilable in 0.8.4, should once again work. Reported by Matthew + Hasselfield. + + Bindings Changes: + + * PYTHON BUG FIX: A spurious debugging message accidentally left in the + 0.8.4 release has been expunged. + +|==============================================================================| + +New in version 0.8.4: + Dirfile Changes: * CLARIFICATION: Inconsistant behaviour in the library, coupled with Modified: trunk/getdata/m4/version.m4 =================================================================== --- trunk/getdata/m4/version.m4 2013-07-29 16:10:17 UTC (rev 844) +++ trunk/getdata/m4/version.m4 2013-09-05 22:19:29 UTC (rev 845) @@ -20,7 +20,7 @@ m4_define(getdata_major, 0) m4_define(getdata_minor, 8) -m4_define(getdata_revision, 4) +m4_define(getdata_revision, 5) m4_define(getdata_extra, []) m4_define(getdata_version, getdata_major.getdata_minor.getdata_revision[]getdata_extra) @@ -28,7 +28,7 @@ dnl libgetdata current interface version m4_define(getdata_iface_version, 6) dnl libgetdata current interface implementation revision -m4_define(getdata_impl_revision, 3) +m4_define(getdata_impl_revision, 4) dnl libgetdata interface age (current interface - oldest supported interface) m4_define(getdata_iface_age, 1) Modified: trunk/getdata/src/zzslim.c =================================================================== --- trunk/getdata/src/zzslim.c 2013-07-29 16:10:17 UTC (rev 844) +++ trunk/getdata/src/zzslim.c 2013-09-05 22:19:29 UTC (rev 845) @@ -37,8 +37,8 @@ * open, idata = 0 otherwise idata = -1. */ int _GD_ZzslimName(DIRFILE *restrict D, const char *restrict enc_data, - struct _gd_raw_file *restrict file, const char *restrict base, - int temp __gd_unused, int resolv) + struct gd_raw_file_ *restrict file, const char *restrict base, + int temp gd_unused_, int resolv) { size_t enc_len; @@ -74,8 +74,8 @@ return 0; } -int _GD_ZzslimOpen(int dirfd, struct _gd_raw_file* file, int swap __gd_unused, - unsigned int mode __gd_unused) +int _GD_ZzslimOpen(int dirfd, struct gd_raw_file_* file, int swap gd_unused_, + unsigned int mode gd_unused_) { char *filepath; @@ -102,8 +102,8 @@ return 0; } -off64_t _GD_ZzslimSeek(struct _gd_raw_file* file, off64_t count, - gd_type_t data_type, unsigned int mode __gd_unused) +off64_t _GD_ZzslimSeek(struct gd_raw_file_* file, off64_t count, + gd_type_t data_type, unsigned int mode gd_unused_) { off64_t n; @@ -121,7 +121,7 @@ return n; } -ssize_t _GD_ZzslimRead(struct _gd_raw_file *restrict file, void *restrict ptr, +ssize_t _GD_ZzslimRead(struct gd_raw_file_ *restrict file, void *restrict ptr, gd_type_t data_type, size_t nmemb) { ssize_t n; @@ -134,7 +134,7 @@ return n; } -int _GD_ZzslimClose(struct _gd_raw_file *file) +int _GD_ZzslimClose(struct gd_raw_file_ *file) { int ret; @@ -151,8 +151,8 @@ return ret; } -off64_t _GD_ZzslimSize(int dirfd, struct _gd_raw_file *file, - gd_type_t data_type, int swap __gd_unused) +off64_t _GD_ZzslimSize(int dirfd, struct gd_raw_file_ *file, + gd_type_t data_type, int swap gd_unused_) { char *filepath; off64_t size; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-29 16:10:21
|
Revision: 844 http://sourceforge.net/p/getdata/code/844 Author: ketiltrout Date: 2013-07-29 16:10:17 +0000 (Mon, 29 Jul 2013) Log Message: ----------- Fix timeout. Modified Paths: -------------- trunk/defile/bin/net.c Modified: trunk/defile/bin/net.c =================================================================== --- trunk/defile/bin/net.c 2013-07-27 12:24:20 UTC (rev 843) +++ trunk/defile/bin/net.c 2013-07-29 16:10:17 UTC (rev 844) @@ -1376,8 +1376,8 @@ /* set up for select */ FD_ZERO(&fds); FD_SET(sock, &fds); - timeout.tv_sec = 0; - timeout.tv_usec = 1000000; + timeout.tv_sec = 1; + timeout.tv_usec = 0; n = select(sock + 1, &fds, NULL, NULL, &timeout); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-27 12:24:24
|
Revision: 843 http://sourceforge.net/p/getdata/code/843 Author: ketiltrout Date: 2013-07-27 12:24:20 +0000 (Sat, 27 Jul 2013) Log Message: ----------- Don't delete df->output Modified Paths: -------------- trunk/defile/bin/defile.c Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-07-27 12:20:38 UTC (rev 842) +++ trunk/defile/bin/defile.c 2013-07-27 12:24:20 UTC (rev 843) @@ -2414,7 +2414,6 @@ free(df->srv_slug[i].data); free(df->srv_slug); free(df->srv_buffer); - free(df->output); for (i = 0; i < df->n_metafiles; ++i) free(df->metafile[i]); @@ -2430,7 +2429,6 @@ df->srv_slug = NULL; df->srv_nslug = 0; df->srv_buffer = 0; - df->output = NULL; df->metafile = NULL; df->n_metafiles = 0; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-27 12:20:41
|
Revision: 842 http://sourceforge.net/p/getdata/code/842 Author: ketiltrout Date: 2013-07-27 12:20:38 +0000 (Sat, 27 Jul 2013) Log Message: ----------- Fix server-side df_reinit. Modified Paths: -------------- trunk/defile/bin/net.c trunk/defile/lib/internal.h trunk/defile/lib/libdefile.c Modified: trunk/defile/bin/net.c =================================================================== --- trunk/defile/bin/net.c 2013-07-25 10:55:55 UTC (rev 841) +++ trunk/defile/bin/net.c 2013-07-27 12:20:38 UTC (rev 842) @@ -1037,6 +1037,25 @@ } } break; + case DF_RPC_HELLO: + /* an extra hello, probably due to a reinit, just get and discard the + * whole thing */ + switch (pos) { + case 0: + string[0] = malloc(DF_HELLO_LEN); + if (string[0] == NULL) { + DF_OOM(DF_PRN_DF); + exit(1); + } + framepos = 0; + pos++; + case 1: + DF_GET_DATA(0, GD_UINT8, DF_HELLO_LEN - 1); + case 2: + free(string[0]); + rpc = -1; + } + break; default: df_dprintf(DF_PRN_ERR, "unhandled rpc from server: %02x\n", (unsigned int)rpc); Modified: trunk/defile/lib/internal.h =================================================================== --- trunk/defile/lib/internal.h 2013-07-25 10:55:55 UTC (rev 841) +++ trunk/defile/lib/internal.h 2013-07-27 12:20:38 UTC (rev 842) @@ -119,8 +119,8 @@ #define DF_RPC_HELLO 0xFF /* the server salutation */ -#define DF_HELLO {DF_RPC_HELLO, 0x0A, 'D', 'E', 'F', 'I', 'L', 'E', 0x0D, 0x0A, DF_SRV_SEX, DF_RPC_VERSION, \ - DF_RPC_REVISION} +#define DF_HELLO {DF_RPC_HELLO, 0x0A, 'D', 'E', 'F', 'I', 'L', 'E', 0x0D, \ + 0x0A, DF_SRV_SEX, DF_RPC_VERSION, DF_RPC_REVISION} #define DF_HELLO_LEN 13 /* private mode flags */ @@ -302,6 +302,7 @@ struct df_rpc *srv_slug; int srv_nslug; pthread_mutex_t srv_mx; + int srv_ind; int nfd; struct df_infdef *fd; Modified: trunk/defile/lib/libdefile.c =================================================================== --- trunk/defile/lib/libdefile.c 2013-07-25 10:55:55 UTC (rev 841) +++ trunk/defile/lib/libdefile.c 2013-07-27 12:20:38 UTC (rev 842) @@ -107,7 +107,7 @@ return df_rc_shell_expand(DF_PRN_INPUT, argument); } -/* Push a RPC ont a slug */ +/* Push a RPC onto a slug */ static int df_rpc_vpush(struct df_rpc *slug, uint8_t rpc, va_list ap) { const struct df_fdef *fd; @@ -1039,10 +1039,10 @@ usleep(10000); } -static int df_init_server(long long length, double rate, const char *name, - int hello) +static int df_init_server(long long length, double rate, const char *name) { if (df->mode_flags & DF_MODE_SERVER) { + df->srv_ind = 0; df->srv_nslug = 1; df->srv_slug = (struct df_rpc *)malloc(sizeof(struct df_rpc)); @@ -1050,7 +1050,7 @@ return DF_OUTPUT; /* server salutation */ - if (hello && df_rpc_push(df->srv_slug, DF_RPC_HELLO)) + if (df_rpc_push(df->srv_slug, DF_RPC_HELLO)) return DF_OUTPUT; if (df_rpc_push(df->srv_slug, DF_RPC_INIT, length, rate, name ? name : @@ -1109,7 +1109,7 @@ } /* good to go -- do the server initialisation, if necessary */ - return df_init_server(length, rate, name, 1); + return df_init_server(length, rate, name); } const char *df_input_name(int shell_expand) @@ -1501,7 +1501,7 @@ pthread_mutex_unlock(&df_rate_mx); /* good to go -- do the server initialisation, if necessary */ - return df_init_server(length, rate, name, 0); + return df_init_server(length, rate, name); } df_abort_func_t df_on_abort(df_abort_func_t abort_func) { @@ -2037,7 +2037,6 @@ int df_add_fragment(const char *name, int parent, unsigned long encoding, unsigned long byte_sex, const char *prefix, const char *suffix) { - static int srv_ind = 0; const int append = df_mode() & DF_MODE_APPEND; int ind; char *path, *ptr; @@ -2049,7 +2048,7 @@ encoding, byte_sex, prefix, suffix); if (ind) return ind; - return ++srv_ind; /* a fake fragment index */ + return ++df->srv_ind; /* a fake fragment index */ } /* make the containing directory */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-25 10:55:58
|
Revision: 841 http://sourceforge.net/p/getdata/code/841 Author: ketiltrout Date: 2013-07-25 10:55:55 +0000 (Thu, 25 Jul 2013) Log Message: ----------- Block SIGPIPE Modified Paths: -------------- trunk/defile/bin/defile.c Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-07-25 09:14:40 UTC (rev 840) +++ trunk/defile/bin/defile.c 2013-07-25 10:55:55 UTC (rev 841) @@ -2837,6 +2837,8 @@ /* block signals */ pthread_sigmask(SIG_BLOCK, &signals, NULL); + signal(SIGPIPE, SIG_IGN); + DF_INSTATE(START); DF_OUTSTATE(START); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-25 09:14:44
|
Revision: 840 http://sourceforge.net/p/getdata/code/840 Author: ketiltrout Date: 2013-07-25 09:14:40 +0000 (Thu, 25 Jul 2013) Log Message: ----------- Don't delete df->output unnecessarily. Modified Paths: -------------- trunk/defile/bin/defile.c Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-07-24 14:11:02 UTC (rev 839) +++ trunk/defile/bin/defile.c 2013-07-25 09:14:40 UTC (rev 840) @@ -1278,8 +1278,6 @@ gd_close(df->D); } - free(df->output); - /* force a final rate printing */ if (!df->quiet && (~df->mode_flags & DF_MODE_SERVER)) DF_PrintRate(1); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-24 14:11:04
|
Revision: 839 http://sourceforge.net/p/getdata/code/839 Author: ketiltrout Date: 2013-07-24 14:11:02 +0000 (Wed, 24 Jul 2013) Log Message: ----------- Fix segfault. Modified Paths: -------------- trunk/defile/bin/net.c Modified: trunk/defile/bin/net.c =================================================================== --- trunk/defile/bin/net.c 2013-07-24 14:10:20 UTC (rev 838) +++ trunk/defile/bin/net.c 2013-07-24 14:11:02 UTC (rev 839) @@ -408,6 +408,7 @@ /* run */ i = df_ready(refname); free(refname); + refname = NULL; if (i < 0) return 1; framecount = framenum - 1; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-24 14:10:22
|
Revision: 838 http://sourceforge.net/p/getdata/code/838 Author: ketiltrout Date: 2013-07-24 14:10:20 +0000 (Wed, 24 Jul 2013) Log Message: ----------- Typos Modified Paths: -------------- trunk/defile/doc/defile-ascii.1 Modified: trunk/defile/doc/defile-ascii.1 =================================================================== --- trunk/defile/doc/defile-ascii.1 2013-07-18 18:27:51 UTC (rev 837) +++ trunk/defile/doc/defile-ascii.1 2013-07-24 14:10:20 UTC (rev 838) @@ -141,10 +141,10 @@ If no field names are provided, defile-ascii will make generic numbered column names of the form -.BI col # -will be used, with the zero-padded numerical part an appropriate width for the -number of columns in the file. Column numbering starts at zero. So, for -example, a file containing four fields will start with +.BI col #\fR, +with the zero-padded numerical part an appropriate width for the number of +columns in the file. Column numbering starts at zero. So, for example, a file +containing four fields will start with .RI """" col0 """" and end with .RI """" col3 """," @@ -219,12 +219,13 @@ .BR ConstRow ) .TP .BR \-d ", " \-\-delim\-req -the start-of-field and end-of-field delimiters are required. (Directive: +the start-of-field and end-of-field delimiters, if any, are required. +(Directive: .BR DelimitersRequired ) .TP .BR +d ", " \-\-delim\-opt -the start-of-field and end-of-field delimiters are option. This is the default. -(Directive: +the start-of-field and end-of-field delimiters are optional. This is the +default. (Directive: .BR DelimitersOptional ) .TP .BR \-e ", " \-\-escape=\fICHAR @@ -277,7 +278,7 @@ .BR Lazy ) .TP .BR +l ", " \-\-strict -prohibit trailing, non-numerical characters after a numberical value. This +prohibit trailing, non-numerical characters after a numerical value. This is the default. (Directive: .BR Strict ) .TP This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-18 18:27:54
|
Revision: 837 http://sourceforge.net/p/getdata/code/837 Author: ketiltrout Date: 2013-07-18 18:27:51 +0000 (Thu, 18 Jul 2013) Log Message: ----------- Use GetData's C89 api for compatibility reasons. Some BSD fixes. Modified Paths: -------------- trunk/defile/bin/defile.c trunk/defile/bin/net.c trunk/defile/input/ascii.c trunk/defile/input/dirfile.c trunk/defile/lib/internal.h trunk/defile/lib/libdefile.c trunk/defile/test/make.c Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/bin/defile.c 2013-07-18 18:27:51 UTC (rev 837) @@ -465,12 +465,12 @@ return df_rpc_push_uint64(slug, u64); } -int df_rpc_push_complex_double(struct df_rpc *slug, complex double v) +int df_rpc_push_complex_double(struct df_rpc *slug, const double v[2]) { - if (df_rpc_push_double(slug, creal(v))) + if (df_rpc_push_double(slug, v[0])) return 1; - return df_rpc_push_double(slug, cimag(v)); + return df_rpc_push_double(slug, v[1]); } /* add a string to the slug */ @@ -1169,7 +1169,6 @@ double delta, rate, drate; long long nf, nw, nr; char si; - struct timezone tz; struct timeval now; pthread_mutex_lock(&df_rate_mx); @@ -1178,7 +1177,7 @@ nr = df->nread; pthread_mutex_unlock(&df_rate_mx); - gettimeofday(&now, &tz); + gettimeofday(&now, NULL); if (final) { delta = (now.tv_sec - df->start.tv_sec) + (now.tv_usec - df->start.tv_usec) / 1e6; @@ -1635,7 +1634,7 @@ return -1; } - if (setsockopt(sock, SOL_TCP, TCP_NODELAY, &n, sizeof(n)) != 0) { + if (setsockopt(sock, IPPROTO_TCP, TCP_NODELAY, &n, sizeof(n)) != 0) { df_dperror(DF_PRN_ERR, "setsockopt"); close(sock); return -1; @@ -1671,7 +1670,6 @@ static int init = 1; static struct timeval then; - struct timezone tz; struct timeval now; int i, have_fd = 0; @@ -1697,7 +1695,7 @@ return nf; /* rate limiting */ - gettimeofday(&now, &tz); + gettimeofday(&now, NULL); if (init) { /* be conservative */ nf = 1; @@ -1815,7 +1813,7 @@ if (listen && pfd[0].revents & POLLIN) { struct sockaddr_in addr; socklen_t addrlen = sizeof(addr); - int sock = accept(pfd[0].fd, &addr, &addrlen); + int sock = accept(pfd[0].fd, (struct sockaddr *)&addr, &addrlen); if (nfds == 1 + DF_MAX_CONNECT) /* too many connections */ close(sock); @@ -2464,9 +2462,6 @@ int main(int argc, char **argv) { - /* rate stuff */ - struct timezone tz; - sigset_t signals; struct sigaction action; @@ -2875,7 +2870,7 @@ if (df->quiet || (df->mode_flags & DF_MODE_SERVER)) { /* In quiet mode, just wait until we're done */ while (DF_ThreadCheck(df, &df->then)) { - gettimeofday(&df->then, &tz); + gettimeofday(&df->then, NULL); sleep(1); } } else { Modified: trunk/defile/bin/net.c =================================================================== --- trunk/defile/bin/net.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/bin/net.c 2013-07-18 18:27:51 UTC (rev 837) @@ -18,6 +18,7 @@ * with Defile; if not, write to the Free Software Foundation, Inc., * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#define GD_C89_API #include "defile.h" #include "internal.h" #include <sys/time.h> @@ -207,18 +208,15 @@ return v; } -static _Complex double df_rpc_get_cdouble(int sock) +static void df_rpc_get_cdouble(double v[2], int sock) { - double _Complex v; uint64_t u[2]; if (df_rpc_get_mem(sock, sizeof(v), u, NULL)) - return 0; + return; u[0] = df_ntohll(u[0]); u[1] = df_ntohll(u[1]); - memcpy(&v, u, sizeof(v)); - - return v; + memcpy(v, u, sizeof(double) * 2); } /* this will malloc the string -- it's a bit tricky, because we might end up @@ -294,7 +292,6 @@ } #define double_t double -#define cdouble_t _Complex double #define DF_GET_SDATUM(v) \ do { \ size_t len; \ @@ -314,6 +311,15 @@ remaining -= sizeof(t ## _t); \ } while(0) +#define DF_GET_CDATUM(v) \ + do { \ + df_rpc_get_cdouble(v, sock); \ + if (ioerr == DFIO_NO_DATA) return 0; \ + if (ioerr) return 1; \ + pos++; \ + remaining -= sizeof(2 * sizeof(double)); \ + } while(0) + #define DF_GET_STRING(n) DF_GET_SDATUM(string[n]) #define DF_GET_PARAM(t,n) DF_GET_DATUM(p_ ## t[n],t) @@ -341,11 +347,7 @@ static int df_do_rpcs(int sock) { static int start = 1; - if (start) { - struct timezone tz; - gettimeofday(&df->start, &tz); - start = 0; - } + static int rpc = -1; static int pos = 0; static int do_reinit_how = -1; @@ -371,6 +373,11 @@ int i, n; size_t part; + if (start) { + gettimeofday(&df->start, NULL); + start = 0; + } + /* check for the sentinal */ if (remaining == 2) { uint16_t sentinal = df_rpc_get_uint16(sock); @@ -479,13 +486,13 @@ case 3: DF_GET_SDATUM(E.in_fields[0]); case 4: - DF_GET_DATUM(E.bitnum, int32); + DF_GET_DATUM(E.u.bit.bitnum, int32); case 5: DF_GET_SDATUM(E.scalar[0]); case 6: DF_GET_DATUM(E.scalar_ind[0], uint32); case 7: - DF_GET_DATUM(E.numbits, int32); + DF_GET_DATUM(E.u.bit.numbits, int32); case 8: DF_GET_SDATUM(E.scalar[1]); case 9: @@ -496,35 +503,35 @@ lastpos = 4; switch (pos) { case 3: - DF_GET_DATUM(E.const_type, uint16); + DF_GET_DATUM(E.u.scalar.const_type, uint16); case 4: - DF_GET_DATUM(E.array_len, uint32); + DF_GET_DATUM(E.u.scalar.array_len, uint32); } break; case GD_CONST_ENTRY: lastpos = 3; if (pos == 3) - DF_GET_DATUM(E.const_type, uint16); + DF_GET_DATUM(E.u.scalar.const_type, uint16); break; case GD_LINCOM_ENTRY: if (pos == 3) { lastpos = 4; - DF_GET_DATUM(E.n_fields, uint8); + DF_GET_DATUM(E.u.lincom.n_fields, uint8); } if (pos > 3) { - lastpos = E.n_fields * 7 + 3; - for (i = 0; i < E.n_fields; ++i) + lastpos = E.u.lincom.n_fields * 7 + 3; + for (i = 0; i < E.u.lincom.n_fields; ++i) switch ((pos - 4) % 7) { case 0: DF_GET_SDATUM(E.in_fields[i]); case 1: - DF_GET_DATUM(E.cm[i], cdouble); + DF_GET_CDATUM(E.u.lincom.cm[i]); case 2: DF_GET_SDATUM(E.scalar[i]); case 3: DF_GET_DATUM(E.scalar_ind[i], uint32); case 4: - DF_GET_DATUM(E.cb[i], cdouble); + DF_GET_CDATUM(E.u.lincom.cb[i]); case 5: DF_GET_SDATUM(E.scalar[i + GD_MAX_LINCOM]); case 6: @@ -538,7 +545,7 @@ case 3: DF_GET_SDATUM(E.in_fields[0]); case 4: - DF_GET_SDATUM(E.table); + DF_GET_SDATUM(E.u.linterp.table); } break; case GD_MPLEX_ENTRY: @@ -549,13 +556,13 @@ case 4: DF_GET_SDATUM(E.in_fields[1]); case 5: - DF_GET_DATUM(E.count_val, int32); + DF_GET_DATUM(E.u.mplex.count_val, int32); case 6: DF_GET_SDATUM(E.scalar[0]); case 7: DF_GET_DATUM(E.scalar_ind[0], uint32); case 8: - DF_GET_DATUM(E.period, int32); + DF_GET_DATUM(E.u.mplex.period, int32); case 9: DF_GET_SDATUM(E.scalar[1]); case 10: @@ -578,7 +585,7 @@ case 3: DF_GET_SDATUM(E.in_fields[0]); case 4: - DF_GET_DATUM(E.shift, int64); + DF_GET_DATUM(E.u.phase.shift, int64); case 5: DF_GET_SDATUM(E.scalar[0]); case 6: @@ -591,14 +598,14 @@ case 3: DF_GET_SDATUM(E.in_fields[0]); case 4: - DF_GET_DATUM(E.poly_ord, uint8); + DF_GET_DATUM(E.u.polynom.poly_ord, uint8); } if (pos > 4) { - lastpos = 3 * (E.poly_ord + 1) + 4; - for (i = 0; i <= E.poly_ord; ++i) + lastpos = 3 * (E.u.polynom.poly_ord + 1) + 4; + for (i = 0; i <= E.u.polynom.poly_ord; ++i) switch ((pos - 5) % 3) { case 0: - DF_GET_DATUM(E.ca[i], cdouble); + DF_GET_CDATUM(E.u.polynom.ca[i]); case 2: DF_GET_SDATUM(E.scalar[i]); case 3: @@ -612,7 +619,7 @@ case 3: DF_GET_SDATUM(E.in_fields[0]); case 4: - DF_GET_DATUM(E.cdividend, cdouble); + DF_GET_CDATUM(E.u.recip.cdividend); case 5: DF_GET_SDATUM(E.scalar[0]); case 6: @@ -630,9 +637,9 @@ case 4: DF_GET_SDATUM(E.in_fields[1]); case 5: - DF_GET_DATUM(E.windop, uint8); + DF_GET_DATUM(E.u.window.windop, uint8); case 6: - DF_GET_DATUM(E.threshold.u, uint64); + DF_GET_DATUM(E.u.window.threshold.u, uint64); case 7: DF_GET_SDATUM(E.scalar[0]); case 8: Modified: trunk/defile/input/ascii.c =================================================================== --- trunk/defile/input/ascii.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/input/ascii.c 2013-07-18 18:27:51 UTC (rev 837) @@ -1444,12 +1444,12 @@ df_exit(1, 1); } else { E.field_type = GD_CONST_ENTRY; - E.const_type = ascii_conf.header[j].type; + E.u.scalar.const_type = ascii_conf.header[j].type; if (df_add_entry(&E)) df_exit(1, 1); - if (df_set_const(E.field, E.const_type, + if (df_set_const(E.field, E.u.scalar.const_type, ((char*)ascii_conf.header[j].data) + GD_SIZE(ascii_conf.header[j].type) * i)) { Modified: trunk/defile/input/dirfile.c =================================================================== --- trunk/defile/input/dirfile.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/input/dirfile.c 2013-07-18 18:27:51 UTC (rev 837) @@ -27,7 +27,6 @@ #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> -#include <complex.h> #include <string.h> #include <stdlib.h> #include <stdio.h> @@ -431,11 +430,11 @@ /* convert the name, if necessary */ if ((ext && !conf.link_lut) || conf.flatten) { size_t old_lut_len = strlen(old_lut); - free(E->table); - E->table = malloc(old_lut_len + conf.lut_dir_len + 2); - sprintf(E->table, "%s%s", conf.lut_dir, old_lut); + free(E->u.linterp.table); + E->u.linterp.table = malloc(old_lut_len + conf.lut_dir_len + 2); + sprintf(E->u.linterp.table, "%s%s", conf.lut_dir, old_lut); lut = malloc(dirfilename_len + old_lut_len + conf.lut_dir_len + 3); - sprintf(lut, "%s/%s", dirfilename, E->table); + sprintf(lut, "%s/%s", dirfilename, E->u.linterp.table); free(old_lut); } else lut = old_lut; @@ -610,11 +609,11 @@ /* set scalar values */ if (E.field_type == GD_CONST_ENTRY) { char buffer[16]; - if (gd_get_constant(D, E.field, E.const_type, buffer)) { + if (gd_get_constant(D, E.field, E.u.scalar.const_type, buffer)) { gd_free_entry_strings(&E); df_exit(1, 1); } - if (df_set_const(E.field, E.const_type, buffer)) { + if (df_set_const(E.field, E.u.scalar.const_type, buffer)) { gd_free_entry_strings(&E); df_exit(1, 1); } @@ -646,17 +645,20 @@ } free(buffer); } else if (E.field_type == GD_CARRAY_ENTRY) { - void *buffer = malloc(E.array_len * GD_SIZE(E.const_type)); + void *buffer = malloc(E.u.scalar.array_len * + GD_SIZE(E.u.scalar.const_type)); if (buffer == NULL) { gd_free_entry_strings(&E); df_exit(1, 1); } - if (gd_get_carray(D, E.field, E.const_type, buffer) < 0) { + if (gd_get_carray(D, E.field, E.u.scalar.const_type, buffer) < 0) { free(buffer); gd_free_entry_strings(&E); df_exit(1, 1); } - if (df_set_carray(E.field, 0, E.array_len, E.const_type, buffer)) { + if (df_set_carray(E.field, 0, E.u.scalar.array_len, + E.u.scalar.const_type, buffer)) + { free(buffer); gd_free_entry_strings(&E); df_exit(1, 1); Modified: trunk/defile/lib/internal.h =================================================================== --- trunk/defile/lib/internal.h 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/lib/internal.h 2013-07-18 18:27:51 UTC (rev 837) @@ -26,12 +26,14 @@ #include "config.h" #endif +#define GD_C89_API +#include <getdata.h> + #include "defile.h" -#include <complex.h> -#include <getdata.h> #include <syslog.h> #include <pthread.h> +#include <stdint.h> #ifdef HAVE_ENDIAN_H #include <endian.h> @@ -346,7 +348,7 @@ int df_rpc_push_uint64(struct df_rpc *slug, uint64_t hv); #define df_rpc_push_int64(s,v) df_rpc_push_uint64((s),(uint64_t)(v)) int df_rpc_push_double(struct df_rpc *slug, double hv); -int df_rpc_push_complex_double(struct df_rpc *slug, complex double v); +int df_rpc_push_complex_double(struct df_rpc *slug, const double v[2]); int df_rpc_push_string(struct df_rpc *slug, const char *str); int df_rpc_push_data(struct df_rpc *slug, gd_type_t type, uint32_t n, const void *data); Modified: trunk/defile/lib/libdefile.c =================================================================== --- trunk/defile/lib/libdefile.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/lib/libdefile.c 2013-07-18 18:27:51 UTC (rev 837) @@ -136,43 +136,43 @@ case GD_BIT_ENTRY: case GD_SBIT_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) - || df_rpc_push_int32(slug, E->bitnum) + || df_rpc_push_int32(slug, E->u.bit.bitnum) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]) - || df_rpc_push_int32(slug, E->numbits) + || df_rpc_push_int32(slug, E->u.bit.numbits) || df_rpc_push_string(slug, E->scalar[1]) || df_rpc_push_uint32(slug, E->scalar_ind[1]); break; case GD_CARRAY_ENTRY: - r = df_rpc_push_uint16(slug, E->const_type) - || df_rpc_push_uint32(slug, E->array_len); + r = df_rpc_push_uint16(slug, E->u.scalar.const_type) + || df_rpc_push_uint32(slug, E->u.scalar.array_len); break; case GD_CONST_ENTRY: - r = df_rpc_push_uint16(slug, E->const_type); + r = df_rpc_push_uint16(slug, E->u.scalar.const_type); break; case GD_LINCOM_ENTRY: - r = df_rpc_push_uint8(slug, E->n_fields); - for (i = 0; !r && i < E->n_fields; ++i) { + r = df_rpc_push_uint8(slug, E->u.lincom.n_fields); + for (i = 0; !r && i < E->u.lincom.n_fields; ++i) { r = df_rpc_push_string(slug, E->in_fields[i]) - || df_rpc_push_complex_double(slug, E->cm[i]) + || df_rpc_push_complex_double(slug, E->u.lincom.cm[i]) || df_rpc_push_string(slug, E->scalar[i]) || df_rpc_push_uint32(slug, E->scalar_ind[i]) - || df_rpc_push_complex_double(slug, E->cb[i]) + || df_rpc_push_complex_double(slug, E->u.lincom.cb[i]) || df_rpc_push_string(slug, E->scalar[i + GD_MAX_LINCOM]) || df_rpc_push_uint32(slug, E->scalar_ind[i + GD_MAX_LINCOM]); } break; case GD_LINTERP_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) - || df_rpc_push_string(slug, E->table); + || df_rpc_push_string(slug, E->u.linterp.table); break; case GD_MPLEX_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) || df_rpc_push_string(slug, E->in_fields[1]) - || df_rpc_push_int32(slug, E->count_val) + || df_rpc_push_int32(slug, E->u.mplex.count_val) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]) - || df_rpc_push_int32(slug, E->period) + || df_rpc_push_int32(slug, E->u.mplex.period) || df_rpc_push_string(slug, E->scalar[1]) || df_rpc_push_uint32(slug, E->scalar_ind[1]); break; @@ -183,22 +183,22 @@ break; case GD_PHASE_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) - || df_rpc_push_int64(slug, E->shift) + || df_rpc_push_int64(slug, E->u.phase.shift) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]); break; case GD_POLYNOM_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) - || df_rpc_push_uint8(slug, E->poly_ord); - for (i = 0; !r && i <= E->poly_ord; ++i) { - r = df_rpc_push_complex_double(slug, E->ca[i]) + || df_rpc_push_uint8(slug, E->u.polynom.poly_ord); + for (i = 0; !r && i <= E->u.polynom.poly_ord; ++i) { + r = df_rpc_push_complex_double(slug, E->u.polynom.ca[i]) || df_rpc_push_string(slug, E->scalar[i]) || df_rpc_push_uint32(slug, E->scalar_ind[i]); } break; case GD_RECIP_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) - || df_rpc_push_complex_double(slug, E->cdividend) + || df_rpc_push_complex_double(slug, E->u.recip.cdividend) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]); break; @@ -207,8 +207,8 @@ case GD_WINDOW_ENTRY: r = df_rpc_push_string(slug, E->in_fields[0]) || df_rpc_push_string(slug, E->in_fields[1]) - || df_rpc_push_uint8(slug, E->windop) - || df_rpc_push_uint64(slug, E->threshold.u) + || df_rpc_push_uint8(slug, E->u.window.windop) + || df_rpc_push_uint64(slug, E->u.window.threshold.u) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]); break; @@ -1132,7 +1132,6 @@ int i, missing = 0, set_reference = 1; const int append = df_mode() & DF_MODE_APPEND; long long offset; - struct timezone tz; DF_CHECK_SEQUENCE(DF_ST_BUILD); @@ -1178,14 +1177,14 @@ "derived type 0x%X\n", df->raw[i].name, E.field_type); gd_free_entry_strings(&E); return DF_OUTPUT; - } else if (E.spf != df->raw[i].spf) { + } else if (E.u.raw.spf != df->raw[i].spf) { df_lprintf(DF_PRN_ERR, "existing raw field %s redefined with " - "different sample rate %u\n", df->raw[i].name, E.spf); + "different sample rate %u\n", df->raw[i].name, E.u.raw.spf); gd_free_entry_strings(&E); return DF_OUTPUT; - } else if (E.data_type != df->raw[i].type) { + } else if (E.u.raw.data_type != df->raw[i].type) { df_lprintf(DF_PRN_ERR, "existing raw field %s redefined with " - "different data type 0x%X\n", df->raw[i].name, E.data_type); + "different data type 0x%X\n", df->raw[i].name, E.u.raw.data_type); gd_free_entry_strings(&E); return DF_OUTPUT; } @@ -1245,7 +1244,7 @@ } /* record our "start" time */ - gettimeofday(&df->start, &tz); + gettimeofday(&df->start, NULL); memcpy(&df->then, &df->start, sizeof(df->then)); /* switch input state */ Modified: trunk/defile/test/make.c =================================================================== --- trunk/defile/test/make.c 2013-07-18 16:05:54 UTC (rev 836) +++ trunk/defile/test/make.c 2013-07-18 18:27:51 UTC (rev 837) @@ -25,6 +25,8 @@ #include "make.h" +#include <stdint.h> + #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> @@ -413,8 +415,8 @@ gd_discard(D); exit(1); } - raws[i].type = E.data_type; - raws[i].spf = E.spf; + raws[i].type = E.u.raw.data_type; + raws[i].spf = E.u.raw.spf; } } else { char *buffer = malloc(strlen(name) + 11); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-18 16:05:57
|
Revision: 836 http://sourceforge.net/p/getdata/code/836 Author: ketiltrout Date: 2013-07-18 16:05:54 +0000 (Thu, 18 Jul 2013) Log Message: ----------- Debug import Modified Paths: -------------- trunk/getdata/bindings/python/pygetdata.c Modified: trunk/getdata/bindings/python/pygetdata.c =================================================================== --- trunk/getdata/bindings/python/pygetdata.c 2013-07-18 00:04:36 UTC (rev 835) +++ trunk/getdata/bindings/python/pygetdata.c 2013-07-18 16:05:54 UTC (rev 836) @@ -506,19 +506,25 @@ int i; PyObject *mod; + dtracevoid(); + if (PyType_Ready(&gdpy_dirfile) < 0) return; + dprintf("gdpy_dirfile ready"); if (PyType_Ready(&gdpy_entry) < 0) return; + dprintf("gdpy_entry ready"); if (PyType_Ready(&gdpy_fragment) < 0) return; + dprintf("gdpy_fragment ready"); #ifdef USE_NUMPY /* The following macro will cause this function to return if importing numpy * fails */ import_array() + dprintf("imported NumPy"); #endif mod = Py_InitModule3("pygetdata", GetDataMethods, @@ -571,28 +577,35 @@ if (mod == NULL) return; + dprintf("module init"); Py_INCREF(&gdpy_dirfile); PyModule_AddObject(mod, "dirfile", (PyObject *)&gdpy_dirfile); + dprintf("gdpy_dirfile added"); Py_INCREF(&gdpy_entry); PyModule_AddObject(mod, "entry", (PyObject *)&gdpy_entry); + dprintf("gdpy_entry added"); Py_INCREF(&gdpy_fragment); PyModule_AddObject(mod, "fragment", (PyObject *)&gdpy_fragment); + dprintf("gdpy_fragment added"); /* version */ PyModule_AddObject(mod, "__version__", Py_BuildValue("(iiis)", GETDATA_MAJOR, GETDATA_MINOR, GETDATA_REVISION, GETDATA_VERSION_SUFFIX)); + dprintf(".__version__ added"); /* author */ PyModule_AddStringConstant(mod, "__author__", "D. V. Wiebe <ge...@ke...>"); + dprintf(".__author__ added"); /* add constants */ for (i = 0; gdpy_constant_list[i].name != NULL; ++i) PyModule_AddIntConstant(mod, gdpy_constant_list[i].name, gdpy_constant_list[i].value); + dprintf("constants added"); PyModule_AddIntConstant(mod, "__numpy_supported__", #ifdef USE_NUMPY @@ -601,6 +614,7 @@ 0 #endif ); + dprintf(".__numpy_supported__ added"); /* add exceptions */ GdPy_DirfileError = PyErr_NewException("pygetdata.DirfileError", @@ -618,4 +632,7 @@ } else gdpy_exceptions[i] = GdPy_DirfileError; } + dprintf("Exceptions added"); + + dreturnvoid(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-07-18 00:04:44
|
Revision: 835 http://sourceforge.net/p/getdata/code/835 Author: ketiltrout Date: 2013-07-18 00:04:36 +0000 (Thu, 18 Jul 2013) Log Message: ----------- Remove debug printf from python; fix make clean in doc/; allow make clean bindings/perl Modified Paths: -------------- trunk/getdata/bindings/perl/Makefile.am trunk/getdata/bindings/python/pydirfile.c trunk/getdata/doc/Makefile.am Modified: trunk/getdata/bindings/perl/Makefile.am =================================================================== --- trunk/getdata/bindings/perl/Makefile.am 2013-06-21 17:19:05 UTC (rev 834) +++ trunk/getdata/bindings/perl/Makefile.am 2013-07-18 00:04:36 UTC (rev 835) @@ -84,7 +84,7 @@ clean-local: rm -rf lib blib if test -e Build; then \ - $(PERL) Build clean; \ + $(PERL) Build clean || true; \ fi rm -f $(BUILT_SOURCES) make_parameters.sed MYMETA.yml MYMETA.json GetData.pm rm -rf Build _build MANIFEST build.stamp t/*~ Modified: trunk/getdata/bindings/python/pydirfile.c =================================================================== --- trunk/getdata/bindings/python/pydirfile.c 2013-06-21 17:19:05 UTC (rev 834) +++ trunk/getdata/bindings/python/pydirfile.c 2013-07-18 00:04:36 UTC (rev 835) @@ -688,7 +688,6 @@ ns = gd_getdata(self->D, field_code, first_frame, first_sample, 0, (size_t)num_samples, return_type, data); - fprintf(stderr, "%zu/%zu\n", ns, (size_t)num_samples); #ifdef USE_NUMPY if (!as_list) { Modified: trunk/getdata/doc/Makefile.am =================================================================== --- trunk/getdata/doc/Makefile.am 2013-06-21 17:19:05 UTC (rev 834) +++ trunk/getdata/doc/Makefile.am 2013-07-18 00:04:36 UTC (rev 835) @@ -53,4 +53,4 @@ unclean_database_recovery.txt clean-local: - rm -rf *~ README.perl + rm -rf *~ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-06-21 17:19:08
|
Revision: 834 http://sourceforge.net/p/getdata/code/834 Author: ketiltrout Date: 2013-06-21 17:19:05 +0000 (Fri, 21 Jun 2013) Log Message: ----------- Update for GetData-0.8.4. Modified Paths: -------------- trunk/defile/bin/Makefile.am trunk/defile/bin/net.c trunk/defile/configure.ac trunk/defile/lib/libdefile.c Modified: trunk/defile/bin/Makefile.am =================================================================== --- trunk/defile/bin/Makefile.am 2013-05-15 00:57:18 UTC (rev 833) +++ trunk/defile/bin/Makefile.am 2013-06-21 17:19:05 UTC (rev 834) @@ -24,4 +24,4 @@ AM_CPPFLAGS = ${GETDATA_CFLAGS} \ -DDEFILE_MODULEDIR="\"${moduledir}\"" ${LTDLINCL} defile_SOURCES = defile.c rc.c net.c rc.h -defile_LDADD = ../lib/libdefile.la -lltdl +defile_LDADD = ../lib/libdefile.la -lltdl ${GETDATA_LIBS} Modified: trunk/defile/bin/net.c =================================================================== --- trunk/defile/bin/net.c 2013-05-15 00:57:18 UTC (rev 833) +++ trunk/defile/bin/net.c 2013-06-21 17:19:05 UTC (rev 834) @@ -555,7 +555,7 @@ case 7: DF_GET_DATUM(E.scalar_ind[0], uint32); case 8: - DF_GET_DATUM(E.count_max, int32); + DF_GET_DATUM(E.period, int32); case 9: DF_GET_SDATUM(E.scalar[1]); case 10: Modified: trunk/defile/configure.ac =================================================================== --- trunk/defile/configure.ac 2013-05-15 00:57:18 UTC (rev 833) +++ trunk/defile/configure.ac 2013-06-21 17:19:05 UTC (rev 834) @@ -136,7 +136,7 @@ echo echo "*** Checking for external libraries" echo -PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.1]) +PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.4]) AC_SEARCH_LIBS([exp],[m]) AC_SEARCH_LIBS([pthread_create],[pthread]) Modified: trunk/defile/lib/libdefile.c =================================================================== --- trunk/defile/lib/libdefile.c 2013-05-15 00:57:18 UTC (rev 833) +++ trunk/defile/lib/libdefile.c 2013-06-21 17:19:05 UTC (rev 834) @@ -172,7 +172,7 @@ || df_rpc_push_int32(slug, E->count_val) || df_rpc_push_string(slug, E->scalar[0]) || df_rpc_push_uint32(slug, E->scalar_ind[0]) - || df_rpc_push_int32(slug, E->count_max) + || df_rpc_push_int32(slug, E->period) || df_rpc_push_string(slug, E->scalar[1]) || df_rpc_push_uint32(slug, E->scalar_ind[1]); break; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-05-15 00:57:19
|
Revision: 833 http://sourceforge.net/p/getdata/code/833 Author: ketiltrout Date: 2013-05-15 00:57:18 +0000 (Wed, 15 May 2013) Log Message: ----------- Tag getdata-0.8.4 Added Paths: ----------- tags/getdata-0.8.4/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-05-15 00:53:38
|
Revision: 832 http://sourceforge.net/p/getdata/code/832 Author: ketiltrout Date: 2013-05-15 00:53:35 +0000 (Wed, 15 May 2013) Log Message: ----------- GetData-0.8.4. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/README trunk/getdata/RELEASE_NOTES.in trunk/getdata/m4/version.m4 Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-05-15 00:52:52 UTC (rev 831) +++ trunk/getdata/ChangeLog 2013-05-15 00:53:35 UTC (rev 832) @@ -1,3 +1,6 @@ +2013-05-14 D. V. Wiebe <ge...@ke...> svn:832 + GetData-0.8.4 released. + 2013-04-11 D. V. Wiebe <ge...@ke...> svn:830 GetData-0.8.4rc2: Modified: trunk/getdata/README =================================================================== --- trunk/getdata/README 2013-05-15 00:52:52 UTC (rev 831) +++ trunk/getdata/README 2013-05-15 00:53:35 UTC (rev 832) @@ -55,9 +55,10 @@ - C++ (libgetdata++) - Fortran 77 (libfgetdata) - Fortran 95 (libf95getdata) - - Python (pygetdata) - the Interactive Data Language (IDL; idl_getdata) + - MATLAB (libgetdata-matlab and associated MEX files) - Perl (GetData.pm) + - Python (pygetdata) Documentation for the various bindings, if present, can be found in files named `README.<language>' in the doc/ directory. The C interface is described @@ -138,7 +139,22 @@ the associated encoding scheme and fail gracefully if encountering dirfiles so encoded. +Building bindings requires appropriate compilers/interpreters and libraries for +the various languages. In particular: +- the C++ bindings require a C++90 compliant compiler +- the Fortran-77 bindings require a Fortran-77 compliant compiler +- the Fortran-95 bindings require both a Fortran-95 compliant compiler and a + Fortran-77 compiler (because the Fortran-95 bindings are built on top of + the Fortran-77 bindings) +- the IDL bindings require a licenced IDL interpreter, version 5.5 or later; + they will not work on an unlicenced interpreter in timed demo mode +- the MATLAB bindings require both a MATLAB interpreter and a MEX compiler +- the Perl bindings require a Perl5 interpreter version 5.6 or later, as well + as the Math::Complex and Module::Build modules. +- the Python bindings require Python 2.3 or later. NumPy is also highly + recommended for efficient use. + USING THE LIBRARY ================= Modified: trunk/getdata/RELEASE_NOTES.in =================================================================== --- trunk/getdata/RELEASE_NOTES.in 2013-05-15 00:52:52 UTC (rev 831) +++ trunk/getdata/RELEASE_NOTES.in 2013-05-15 00:53:35 UTC (rev 832) @@ -1,4 +1,4 @@ -GetData 0.8.3 is known to compile and pass the test suite on the following +GetData 0.8.4 is known to compile and pass the test suite on the following systems (including C++ and Fortran bindings): Linux: @@ -21,11 +21,11 @@ --------------------------------------------------------------------------- Four packages are available: -* getdata-0.8.3.tar.bz2/.gz: the full source code to the library, with +* getdata-0.8.4.tar.bz2/.gz: the full source code to the library, with bindings. This package uses the GNU autotools build system, and is designed for POSIX systems (UNIX, Linux, BSD, MacOS X, Cygwin, MSys, &c.) -* getdata_win-0.8.3.zip: a reduced source code package, with the CMake +* getdata_win-0.8.4.zip: a reduced source code package, with the CMake build system designed to be built on Microsoft Windows, either using the free MinGW compiler, or else Microsoft's Visual C++ compiler. (The full source package above can also be built using MinGW, if the @@ -34,12 +34,12 @@ package lacks support for compressed dirfiles, the Legacy API, and a few other features. This build is used in native Microsoft Windows builds of kst2. -* idl_getdata-0.8.3.tar.bz2/.gz: the Interactive Data Language (IDL) +* idl_getdata-0.8.4.tar.bz2/.gz: the Interactive Data Language (IDL) bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, pre-built packages rarely come with these bindings, and this package allows end-users to add support for IDL -* matlab_getdata-0.8.3.tar.bz2/.gz: the MATLAB bindings, packaged separately +* matlab_getdata-0.8.4.tar.bz2/.gz: the MATLAB bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, pre-built packages rarely come with these bindings, and this package allows end-users Modified: trunk/getdata/m4/version.m4 =================================================================== --- trunk/getdata/m4/version.m4 2013-05-15 00:52:52 UTC (rev 831) +++ trunk/getdata/m4/version.m4 2013-05-15 00:53:35 UTC (rev 832) @@ -21,7 +21,7 @@ m4_define(getdata_major, 0) m4_define(getdata_minor, 8) m4_define(getdata_revision, 4) -m4_define(getdata_extra, [rc2]) +m4_define(getdata_extra, []) m4_define(getdata_version, getdata_major.getdata_minor.getdata_revision[]getdata_extra) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-05-15 00:52:54
|
Revision: 831 http://sourceforge.net/p/getdata/code/831 Author: ketiltrout Date: 2013-05-15 00:52:52 +0000 (Wed, 15 May 2013) Log Message: ----------- Update. Modified Paths: -------------- trunk/html/dirfile.html.in trunk/html/download.html.in trunk/html/index.html.in Modified: trunk/html/dirfile.html.in =================================================================== --- trunk/html/dirfile.html.in 2013-04-11 00:05:22 UTC (rev 830) +++ trunk/html/dirfile.html.in 2013-05-15 00:52:52 UTC (rev 831) @@ -596,7 +596,7 @@ (numbered from zero) of <span class="syntax"><input></span> (when <span class="syntax"><input></span> is converted to an endianness-corrected unsigned 64-bit integer). If <span class="syntax" - ><bits></span> is omitted, it is assumed to be <b>1</b>. + ><num-bits></span> is omitted, it is assumed to be <b>1</b>. Standards Version 0 doesn't recognise the <span class="syntax"><num-bits></span> token. <li><b>CARRAY</b>: The CARRAY scalar field type is an list of constants @@ -672,7 +672,7 @@ sample rate. Syntax is: <div class="syntax"> <fieldname> <b>MPLEX</b> <input> <index> - <count> [<max>] + <count> [<period>] </div> where <ul> @@ -683,13 +683,12 @@ <li><span class="syntax"><count></span> is the value of the multiplex index when the computed field is stored in <span class="syntax"><input></span>, and - <li><span class="syntax"><max></span> is the nominal maximum - value which the multiplex index takes. If given and non-zero, the - relation <span class="syntax"><count> ≤ <max></span> - must hold. + <li><span class="syntax"><period></span> is the nominal period + (in samples) between successive occurances of <span + class="syntax"><count></span> in the index field. If not + given, or zero, the period is assumed to be unknown or non-constant. + If given, it must be non-negative. </ul> - Both <span class="syntax"><count></span> and <span - class="syntax"><max></span> are non-negative integers. <p>At every sample <i>n</i>, the derived field is computed as: <div class="inset"><img class="math" src="mplex_computation.png" alt="fieldname[n] = (index == count) ? input[n] : fieldname[n - 1]" @@ -703,17 +702,15 @@ GetData searches backwards for its value, but see the <span class="syntax">gd_mplex_lookback()</span> function. <p>The values of <span class="syntax"><count></span> and <span - class="syntax"><max></span> place no restrictions on values + class="syntax"><period></span> place no restrictions on values contained in <span class="syntax"><index></span>. Specifically, - samples of <span class="syntax"><index></span> may exceed <span - class="syntax"><max></span>. Particular values of <span - class="syntax"><index></span> (including <span - class="syntax"><count></span>) need not be equally spaced - (neither by <span class="syntax"><max></span> nor any other - spacing); <span class="syntax"><index></span> need not ever take - on the value <span class="syntax"><count></span> (in which case - GetData will return 0 or NaN for the entirety of the output vector). - MPLEX appeared in Standards Version 9. + particular values of <span class="syntax"><index></span> + (including <span class="syntax"><count></span>) need not be + equally spaced (neither by <span class="syntax"><period></span> + nor any other spacing); <span class="syntax"><index></span> need + not ever take on the value <span class="syntax"><count></span> (in + which case GetData will return 0 or NaN for the entirety of the output + vector). MPLEX appeared in Standards Version 9. <li><b>MULTIPLY</b>: The MULTIPLY field type is the product of two vector fields. Syntax is: <div class="syntax"><fieldname> <b>MULTIPLY</b> @@ -939,7 +936,7 @@ class="syntax">m</span><sub>i</sub> or <span class="syntax">b</span><sub>i</sub> <li><b>MPLEX</b>: <span class="syntax">count</span>, - <span class="syntax">max</span> + <span class="syntax">period</span> <li><b>PHASE</b>: <span class="syntax">shift</span> <li><b>POLYNOM</b>: any of the <span class="syntax">a</span><sub>i</sub> @@ -1109,8 +1106,8 @@ </tr> </table> </div> - <div class="foot"><div class="copy">© 2008, 2009, 2010, 2011, 2012 - D. V. Wiebe</div> + <div class="foot"><div class="copy">© 2008, 2009, 2010, 2011, 2012, + 2013 D. V. Wiebe</div> <div class="w3c"> <a href="http://validator.w3.org/check?uri=referer"><img src="valid_html.png" alt="Valid HTML 4.01 Strict" height="21" Modified: trunk/html/download.html.in =================================================================== --- trunk/html/download.html.in 2013-04-11 00:05:22 UTC (rev 830) +++ trunk/html/download.html.in 2013-05-15 00:52:52 UTC (rev 831) @@ -21,17 +21,17 @@ <h2><a name="source">Latest Release</a></h2> <p>The complete source code for official releases of the GetData project are available from SourceForge. The latest version of GetData, released - 12 March, 2013, is: + 14 May, 2013, is: <ul> <li><a - href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/" - >0.8.3</a>. Four packages are available: + href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/" + >0.8.4</a>. Four packages are available: <dl> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/getdata-0.8.3.tar.bz2/download">getdata-0.8.3.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/getdata-0.8.3.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata-0.8.4.tar.bz2/download">getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata-0.8.4.tar.gz/download">.gz</a>:</dt> <dd>The full source code to the library, with bindings. This package uses the GNU autotools build system, and is designed for POSIX systems (UNIX, Linux, BSD, MacOS X, Cygwin, MSys, &c.)</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/getdata_win-0.8.3.zip/download">getdata_win-0.8.3.zip</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/getdata_win-0.8.4.zip/download">getdata_win-0.8.4.zip</a>:</dt> <dd>A reduced source code package, with the CMake build system designed to be built on Microsoft Windows, either using the free MinGW compiler, or else Microsoft's Visual C++ compiler. (The full source @@ -41,14 +41,14 @@ compressed dirfiles, the Legacy API, and a few other features. This build is used in native Microsoft Windows builds of <a href="http://kst.kde.org/">kst-2</a>.</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/idl_getdata-0.8.3.tar.bz2/download">idl_getdata-0.8.3.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/idl_getdata-0.8.3.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/idl_getdata-0.8.4.tar.bz2/download">idl_getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/idl_getdata-0.8.4.tar.gz/download">.gz</a>:</dt> <dd>The Interactive Data Language (IDL) bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, <a href="#distro">pre-built packages</a> rarely come with these bindings, and this package allows end-users to add support for IDL without having to recompile the whole GetData package.</dd> - <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/matlab_getdata-0.8.3.tar.bz2/download">matlab_getdata-0.8.3.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/matlab_getdata-0.8.3.tar.gz/download">.gz</a>:</dt> + <dt><a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/matlab_getdata-0.8.4.tar.bz2/download">matlab_getdata-0.8.4.tar.bz2</a>/<a href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/matlab_getdata-0.8.4.tar.gz/download">.gz</a>:</dt> <dd>The MATLAB bindings, packaged separately with an autotools build system, designed to be built against an already installed version of GetData. Due to licensing restrictions, <a href="#distro">pre-built @@ -136,8 +136,8 @@ <p>Older getdata releases available include the following: <ul> <li><a - href="http://sourceforge.net/projects/getdata/files/getdata/0.8.2/" - >0.8.2</a>—<i>December 2012</i> + href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/" + >0.8.3</a>—<i>March 2013</i> <li><a href="http://sourceforge.net/projects/getdata/files/getdata/0.7.3/" >0.7.3</a>—<i>April 2011</i> Modified: trunk/html/index.html.in =================================================================== --- trunk/html/index.html.in 2013-04-11 00:05:22 UTC (rev 830) +++ trunk/html/index.html.in 2013-05-15 00:52:52 UTC (rev 831) @@ -59,9 +59,9 @@ <p>The complete source code for official releases of the GetData project are available from SourceForge. <ul><li> - The latest version of GetData, released 12 March, 2012, is <a - href="http://sourceforge.net/projects/getdata/files/getdata/0.8.3/" - >GetData 0.8.3</a>.</ul> + The latest version of GetData, released 14 May, 2013, is <a + href="http://sourceforge.net/projects/getdata/files/getdata/0.8.4/" + >GetData 0.8.4</a>.</ul> See: <ul><li><a href="download.html">Get GetData</a></ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-11 00:05:32
|
Revision: 830 http://sourceforge.net/p/getdata/code/830 Author: ketiltrout Date: 2013-04-11 00:05:22 +0000 (Thu, 11 Apr 2013) Log Message: ----------- GetData-0.8.4rc2: build system fixes. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/NEWS trunk/getdata/bindings/idl/package/configure.ac trunk/getdata/bindings/matlab/package/configure.ac trunk/getdata/bindings/perl/Build.PL.in trunk/getdata/m4/version.m4 Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/ChangeLog 2013-04-11 00:05:22 UTC (rev 830) @@ -1,3 +1,11 @@ +2013-04-11 D. V. Wiebe <ge...@ke...> svn:830 + GetData-0.8.4rc2: + + * bindings/perl/Build.PL.in: make include_dirs an array. Reported by Seth. + + * bindings/idl/package/configure.ac bindings/matlab/package/configure.ac: + Require GetData >= 0.8.4. + 2013-04-10 D. V. Wiebe <ge...@ke...> svn:829 GetData-0.8.4rc1. Modified: trunk/getdata/NEWS =================================================================== --- trunk/getdata/NEWS 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/NEWS 2013-04-11 00:05:22 UTC (rev 830) @@ -1,4 +1,4 @@ -New in version 0.8.4a: +New in version 0.8.4rc2: Dirfile Changes: Modified: trunk/getdata/bindings/idl/package/configure.ac =================================================================== --- trunk/getdata/bindings/idl/package/configure.ac 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/bindings/idl/package/configure.ac 2013-04-11 00:05:22 UTC (rev 830) @@ -126,7 +126,7 @@ echo echo "*** Looking for getdata" echo -PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.0]) +PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.4]) dnl headers echo Modified: trunk/getdata/bindings/matlab/package/configure.ac =================================================================== --- trunk/getdata/bindings/matlab/package/configure.ac 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/bindings/matlab/package/configure.ac 2013-04-11 00:05:22 UTC (rev 830) @@ -136,7 +136,7 @@ echo echo "*** Looking for getdata" echo -PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.0]) +PKG_CHECK_MODULES([GETDATA], [getdata >= 0.8.4]) dnl types echo Modified: trunk/getdata/bindings/perl/Build.PL.in =================================================================== --- trunk/getdata/bindings/perl/Build.PL.in 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/bindings/perl/Build.PL.in 2013-04-11 00:05:22 UTC (rev 830) @@ -42,7 +42,7 @@ dist_version_from => "GetData.pm", extra_compiler_flags => ['@DEFS@', '-I@top_builddir@/src'], extra_linker_flags => ['-L@top_builddir@/src/.libs/', '-lgetdata'], - include_dirs => '@top_srcdir@/src', + include_dirs => ['@top_srcdir@/src'], license => 'lgpl', module_name => "GetData", pm_files => { 'GetData.pm' => 'lib/GetData.pm' }, Modified: trunk/getdata/m4/version.m4 =================================================================== --- trunk/getdata/m4/version.m4 2013-04-10 02:21:09 UTC (rev 829) +++ trunk/getdata/m4/version.m4 2013-04-11 00:05:22 UTC (rev 830) @@ -21,7 +21,7 @@ m4_define(getdata_major, 0) m4_define(getdata_minor, 8) m4_define(getdata_revision, 4) -m4_define(getdata_extra, [rc1]) +m4_define(getdata_extra, [rc2]) m4_define(getdata_version, getdata_major.getdata_minor.getdata_revision[]getdata_extra) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-10 02:21:13
|
Revision: 829 http://sourceforge.net/p/getdata/code/829 Author: ketiltrout Date: 2013-04-10 02:21:09 +0000 (Wed, 10 Apr 2013) Log Message: ----------- GetData-0.8.4rc1. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/m4/version.m4 Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-04-06 02:26:25 UTC (rev 828) +++ trunk/getdata/ChangeLog 2013-04-10 02:21:09 UTC (rev 829) @@ -1,3 +1,6 @@ +2013-04-10 D. V. Wiebe <ge...@ke...> svn:829 + GetData-0.8.4rc1. + 2013-04-06 D. V. Wiebe <ge...@ke...> svn:827 * bindings/cxx/getdata/entry.h (Entry::CountMax) bindings/cxx/getdata/mplexentry.h (MplexEntry::CountMax Modified: trunk/getdata/m4/version.m4 =================================================================== --- trunk/getdata/m4/version.m4 2013-04-06 02:26:25 UTC (rev 828) +++ trunk/getdata/m4/version.m4 2013-04-10 02:21:09 UTC (rev 829) @@ -21,25 +21,25 @@ m4_define(getdata_major, 0) m4_define(getdata_minor, 8) m4_define(getdata_revision, 4) -m4_define(getdata_extra, [a]) +m4_define(getdata_extra, [rc1]) m4_define(getdata_version, getdata_major.getdata_minor.getdata_revision[]getdata_extra) dnl libgetdata current interface version m4_define(getdata_iface_version, 6) dnl libgetdata current interface implementation revision -m4_define(getdata_impl_revision, 2) +m4_define(getdata_impl_revision, 3) dnl libgetdata interface age (current interface - oldest supported interface) m4_define(getdata_iface_age, 1) dnl libgetdata++ interface version info -m4_define(getdataxx_version, 4:0:1) +m4_define(getdataxx_version, 5:0:2) dnl libfgetdata interface version info -m4_define(fgetdata_version, 4:0:2) +m4_define(fgetdata_version, 4:1:2) dnl libf95getdata interface version info -m4_define(f95getdata_version, 4:0:2) +m4_define(f95getdata_version, 5:0:3) dnl libgetdata-matlab interface version info -m4_define(matlabgetdata_version, 0:0:0) +m4_define(matlabgetdata_version, 0:1:0) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-06 02:26:31
|
Revision: 828 http://sourceforge.net/p/getdata/code/828 Author: ketiltrout Date: 2013-04-06 02:26:25 +0000 (Sat, 06 Apr 2013) Log Message: ----------- Remove parallel build race condition. Modified Paths: -------------- trunk/getdata/bindings/perl/Makefile.am Modified: trunk/getdata/bindings/perl/Makefile.am =================================================================== --- trunk/getdata/bindings/perl/Makefile.am 2013-04-06 02:17:09 UTC (rev 827) +++ trunk/getdata/bindings/perl/Makefile.am 2013-04-06 02:26:25 UTC (rev 828) @@ -39,7 +39,7 @@ nodist_perlautogetdata_SCRIPTS=blib/arch/auto/GetData/GetData.bs blib/arch/auto/GetData/GetData.so lib: - mkdir $@ + mkdir -p $@ lib/GetData.xs: GetData.xs $(MAKE) lib This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-06 02:17:13
|
Revision: 827 http://sourceforge.net/p/getdata/code/827 Author: ketiltrout Date: 2013-04-06 02:17:09 +0000 (Sat, 06 Apr 2013) Log Message: ----------- Re-implement CountMax/SetCoutMax in C++ for backwards compatiblity. Fix perl mandir. Doc updates. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/NEWS trunk/getdata/bindings/cxx/getdata/entry.h trunk/getdata/bindings/cxx/getdata/mplexentry.h trunk/getdata/configure.ac trunk/getdata/doc/README.cxx trunk/getdata/doc/README.f77 trunk/getdata/doc/README.f95 trunk/getdata/doc/README.idl trunk/getdata/doc/README.matlab trunk/getdata/m4/perl.m4 trunk/getdata/man/dirfile-format.5 Added Paths: ----------- trunk/getdata/doc/README.perl Removed Paths: ------------- trunk/getdata/doc/README.perl.in Property Changed: ---------------- trunk/getdata/doc/ Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/ChangeLog 2013-04-06 02:17:09 UTC (rev 827) @@ -1,3 +1,9 @@ +2013-04-06 D. V. Wiebe <ge...@ke...> svn:827 + * bindings/cxx/getdata/entry.h (Entry::CountMax) + bindings/cxx/getdata/mplexentry.h (MplexEntry::CountMax + MplexEntry::SetCountMax): Added (but marked deprecated) for backwards + compatibility. + 2013-04-05 D. V. Wiebe <ge...@ke...> svn:826 * bindings/f77/test/big_test.f bindings/f77/test/big_test95.f90 bindings/perl/t/big_test.t: Fix test 231. Modified: trunk/getdata/NEWS =================================================================== --- trunk/getdata/NEWS 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/NEWS 2013-04-06 02:17:09 UTC (rev 827) @@ -1,56 +1,89 @@ New in version 0.8.4a: + Dirfile Changes: + + * CLARIFICATION: Inconsistant behaviour in the library, coupled with + contradictory statements in the Dirfile Standards, has resulted in confusion + over the meaning of the final, optional, parameter in a MPLEX definition. + To be clear: this parameter is simply the expected period between successive + occurances of the "count" value in the index vector. (It is used by GetData + only to figure out a resonable length for the MPLEX lookback.) The + following clarifications and corrections have been made to the definition + of the MPLEX field type in dirfile-format(5): + + - The final, optional parameter has been renamed from "max" to "period". + + - This parameter indicates not the maximal range of the index vector, as + previously stated, but the expected number of samples between successive + occurances of the specified "count" value in the index vector; as before, + it should be regarded as a hint, and does not place any actual restriction + on the contents of the index vector. + + - The incorrect requirement that the "count" parameter be non-negative has + been deleted. + + - The incorrect requirement that "count" be less than or equal to "max", if + "max" is present and non-zero, has been deleted. + + - The meaning of an omitted or zero "period", indicating that the spacing of + "count" in the index vector is unknown or non-uniform, is now explicitly + stated. + + - Different MPLEX fields using the same index vector may specify different + periods. + + See also the related library bug fixes below. + Library Changes: - * BUG FIX: Inconsistant behaviour in the library, coupled with contradictory - statements in the Dirfile Standards, has resulted in confusion over the - meaning of the final, optional, parameter in a MPLEX definition. To be clear: - this parameter is simply the expected period between successive occurances of - the mplex value in the index vector. It is used by GetData only to figure out - a resonable length of the MPLEX lookback. To help reduce confusion, this - parameter has been renamed from "count_max" to "period". The Standards have - also been clarified. See also the following related bug fixes. + * The count_max member of the gd_entry_t object has been renamed period. The + corresponding dummy argument in various function prototypes has been + similarly renamed. - * BUG FIX: The count_val MPLEX parameter is not restricted to non-negative - numbers. + * BUG FIX: The library no longer incorrectly rejects negative count_val MPLEX + parameters. Furthermore, a count_val of -1 in gd_alter_entry or + gd_[m]alter_mplex calls is not a special value: it just sets count_val to + -1. - * BUG FIX: The optional period (formerly count_max) MPLEX parameter does not - restrict allowed values of the count_val parameter. + * BUG FIX: The library no longer incorrectly rejects MPLEX fields where + count_val is greater than the period (formerly called count_max). * BUG FIX: The default MPLEX period, if none is specified, is 2*count_val + 1, - not simply 2 * count_val, when count_val is greater than 5. + not simply 2 * count_val, when count_val is greater than 5. - * BUG FIX: A count_val of -1 in gd_alter_entry or gd_[m]alter_mplex calls is - not a special value: it just sets the count_val to -1. - * BUG FIX: Trying to position an I/O pointer to before sample zero with - gd_seek() now properly fails. Previously it would allow it, causing bizarre - things to happen later. + gd_seek() now properly fails. Previously it would allow it, causing bizarre + things to happen later. * BUG FIX: Using gd_tell to get the I/O pointer position of a derived field - with exactly two input fields (MULTIPLY, DIVIDE, MPLEX, WINDOW) now properly - reports an error in the "multiposition" case (ie. when the two inputs are - ultimately reading from different locations in the same RAW field). + with exactly two input fields (MULTIPLY, DIVIDE, MPLEX, WINDOW) now properly + reports an error in the "multiposition" case (ie. when the two inputs are + ultimately reading from different locations in the same RAW field). * BUG FIX: Trying to read sample zero of a gzipped RAW field the second time - now works as expected. Previously, the request to reposition the I/O pointer - back to zero would be ignored by the gzip framework. Reported by Alexandra - Rahlin. + now works as expected. Previously, the request to reposition the I/O + pointer back to zero would be ignored by the gzip framework. Reported by + Alexandra Rahlin. * BUG FIX: The field code of a reference field declared in a subfragment - included with affixes is no longer corrupted by spurious application of the - affixes when the subfragment's metadata are (re-)written. Reported by Seth. + included with affixes is no longer corrupted by spurious application of the + affixes when the subfragment's metadata are (re-)written. Reported by Seth. Bindings Changes: - * IDL BUG FIX: Entry structs representing MPLEX fields are now properly - interpreted. Previously, the underlying gd_entry_t object was being - incorrectly initialised. + * C++: The Entry and MplexEntry member functions CountMax and SetCountMax have + been renamed to Period and SetPeriod for consistency with the changes listed + above. CountMax and SetCountMax are still avaialbe as aliases, but are + marked deprecated. + * IDL BUG FIX: GD_ENTRY structures representing MPLEX fields are now properly + interpreted. Previously, the underlying gd_entry_t object was being + incorrectly initialised. + * PYTHON BUG FIX: Numpy arrays returned by dirfile.getdata() are now the - correct length. Previously they would always be the length requested (or the - length of the dirfile, if no length was explicitly given) even if fewer - samples were returned. Extra elements would contain uninitialised memory. + correct length. Previously they would always be the length requested (or + the length of the dirfile, if no length was explicitly given) even if fewer + samples were returned. Extra elements would contain uninitialised memory. |==============================================================================| @@ -59,27 +92,28 @@ Library Changes: * BUG FIX: Several bugs on big-ended systems have been fixed. Reported by - Dinar Valeev. + Dinar Valeev. * BUG FIX: Adding an entry via gd_[m]add() with a negative CARRAY scalar index - no longer results in an internal error or worse when the added field is later - read. + no longer results in an internal error or worse when the added field is + later read. * BUG FIX: Changing a CONST field to a real floating point type using - gd_alter_const() (or similar) no longer results in the value of the field - being corrupted. + gd_alter_const() (or similar) no longer results in the value of the field + being corrupted. * BUG FIX: A bug in the parser's tokeniser has been fixed to prevent spurious - "unterminated token" syntax errors. Typically this would only be seen when - using gd_strtok() to tokenise an (apparently innocuous) user-supplied string, - but a carefully crafted format file could also be made to get gd_open() to - produce it. + "unterminated token" syntax errors. Typically this would only be seen when + using gd_strtok() to tokenise an (apparently innocuous) user-supplied + string, but a carefully crafted format file could also be made to get + gd_open() to produce it. Bindings Changes: * Bindings for MATLAB have been added. + * The IDL, Perl, and Python bindings no longer require a C99 compiler to be - built. + built. |==============================================================================| Modified: trunk/getdata/bindings/cxx/getdata/entry.h =================================================================== --- trunk/getdata/bindings/cxx/getdata/entry.h 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/bindings/cxx/getdata/entry.h 2013-04-06 02:17:09 UTC (rev 827) @@ -228,6 +228,9 @@ return (E.field_type == GD_MPLEX_ENTRY) ? E.u.mplex.period : 0; } + /* deprecated member alias */ + virtual int gd_deprecated CountMax() const { return Period(); } + /* Set methods */ void SetName(const char* name); Modified: trunk/getdata/bindings/cxx/getdata/mplexentry.h =================================================================== --- trunk/getdata/bindings/cxx/getdata/mplexentry.h 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/bindings/cxx/getdata/mplexentry.h 2013-04-06 02:17:09 UTC (rev 827) @@ -56,6 +56,15 @@ virtual int SetPeriod(int period); virtual int SetPeriod(const char* period); + /* deprecated member aliases */ + virtual int gd_deprecated CountMax() const { return Period(); }; + virtual int gd_deprecated SetCountMax(int period) { + return SetPeriod(period); + } + virtual int gd_deprecated SetCountMax(const char* period) { + return SetPeriod(period); + }; + private: MplexEntry(const GetData::Dirfile *dirfile, const char* field_code) : Entry(dirfile, field_code) { }; Modified: trunk/getdata/configure.ac =================================================================== --- trunk/getdata/configure.ac 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/configure.ac 2013-04-06 02:17:09 UTC (rev 827) @@ -1036,9 +1036,6 @@ AC_CONFIG_FILES([bindings/python/Makefile]) AC_CONFIG_FILES([bindings/python/test/Makefile]) AC_CONFIG_FILES([doc/Makefile]) -if test "x$make_perlbindings" != "xno"; then -AC_CONFIG_FILES([doc/README.perl]) -fi AC_CONFIG_FILES([man/Makefile]) AC_CONFIG_FILES([man/gd_alter_encoding.3]) AC_CONFIG_FILES([man/gd_alter_endianness.3]) Index: trunk/getdata/doc =================================================================== --- trunk/getdata/doc 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc 2013-04-06 02:17:09 UTC (rev 827) Property changes on: trunk/getdata/doc ___________________________________________________________________ Modified: svn:ignore ## -1,3 +1,2 ## Makefile.in Makefile -README.perl Modified: trunk/getdata/doc/README.cxx =================================================================== --- trunk/getdata/doc/README.cxx 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.cxx 2013-04-06 02:17:09 UTC (rev 827) @@ -400,7 +400,7 @@ * virtual WindOpType Entry::WindOp() * virtual gd_triplet_t Entry::Threshold() * virtual int Entry::CountVal() -* virtual int Entry::CountMax() +* virtual int Entry::Period() These methods will return the corresponding member of the gd_entry_t object. Only methods reasonable to be queried for the given field type will return @@ -767,7 +767,7 @@ * virtual const char *MplexEntry::Scalar() * virtual int MplexEntry::ScalarIndex() * virtual int MplexEntry::CountVal() -* virtual int MplexEntry::CountMax() +* virtual int MplexEntry::Period() These methods, re-implemented from the Entry class, return the corresponding field parameter. @@ -776,8 +776,8 @@ * int MplexEntry::SetWindOp(WindOpType coeff) * int MplexEntry::SetCountVal(int count_val) * int MplexEntry::SetCountVal(const char *count_val) -* int MplexEntry::SetCountMax(int count_max) -* int MplexEntry::SetCountMax(const char *count_max) +* int MplexEntry::SetPeriod(int period) +* int MplexEntry::SetPeriod(const char *period) These functions will change the specified input field, check field, or the count value or max to the value or field code supplied. Modified: trunk/getdata/doc/README.f77 =================================================================== --- trunk/getdata/doc/README.f77 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.f77 2013-04-06 02:17:09 UTC (rev 827) @@ -1132,11 +1132,11 @@ specified is not of POLYNOM type, infield_len will be set to zero. In this case the value of the remaining data is unspecified. -* GDGEMX(infield, infield_len, countfield, countfield_len, countval, countmax, +* GDGEMX(infield, infield_len, countfield, countfield_len, countval, period, fragment_index, dirfile_unit, field_code, field_code_len) Output: - INTEGER countval, countmax, fragment_index + INTEGER countval, period, fragment_index CHARACTER*<infield_len> infield CHARACTER*<countfield_len> countfield Input/Output: @@ -1460,11 +1460,11 @@ should be of type integer, otherwise it should be double precision. * GDALMX(dirfile_unit, field_code, field_code_len, infield, infield_len, - countfield, countfield_len, countval, countmax) + countfield, countfield_len, countval, period) Input: INTEGER dirfile_unit, field_code_len, infield_len, countfile_len, countval - INTEGER countmax + INTEGER period CHARACTER*<field_code_len> field_code CHARACTER*<infield_len> infield CHARACTER*<countfield_len> countfield @@ -1837,11 +1837,11 @@ should be of type double precision. * GDADMX(dirfile_unit, field_code, field_code_len, infield, infield_len, - countfield, countfield_len, countval, countmax, fragment_index) + countfield, countfield_len, countval, period, fragment_index) Input: INTEGER dirfile_unit, field_code_len, infield_len, countfile_len, countval - INTEGER countmax, fragment_index + INTEGER period, fragment_index CHARACTER*<field_code_len> field_code CHARACTER*<infield_len> infield CHARACTER*<countfield_len> countfield @@ -1939,7 +1939,7 @@ * GDMDWD(dirfile_unit, parent, field_code, field_code_len, in_field, in_field_len, check_field, check_field_len, windop, threshold) * GDMDMX(dirfile_unit, parent, field_code, field_code_len, in_field, - in_field_len, count_field, count_field_len, count_val, count_max) + in_field_len, count_field, count_field_len, count_val, period) * GDMDCA(dirfile_unit, parent, parent_len, field_code, field_code_len, const_type, array_len, data_type, data) * GDMDCO(dirfile_unit, parent, parent_len, field_code, field_code_len, Modified: trunk/getdata/doc/README.f95 =================================================================== --- trunk/getdata/doc/README.f95 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.f95 2013-04-06 02:17:09 UTC (rev 827) @@ -231,9 +231,9 @@ character (len=*), intent(in) :: field_name, in_field, table * subroutine fgd_add_mplex (dirfile, field_code, in_field, count_field, - count_val, count_max, fragment_index) + count_val, period, fragment_index) character(len=*), intent(in) :: field_code, in_field, count_field - integer, intent(in) :: dirfile, count_val, count_max, fragment_index + integer, intent(in) :: dirfile, count_val, period, fragment_index * subroutine fgd_add_multiply (dirfile, field_name, in_field1, in_field2, fragment_index) @@ -353,9 +353,9 @@ character (len=*), intent(in) :: field_name, in_field, table, parent * subroutine fgd_madd_mplex (dirfile, parent, field_code, in_field, count_field, - count_val, count_max) + count_val, period) character(len=*), intent(in) :: parent, field_code, in_field, count_field - integer, intent(in) :: dirfile, count_val, count_max + integer, intent(in) :: dirfile, count_val, period * subroutine fgd_madd_phase (dirfile, parent, field_name, in_field, phase) integer, intent(in) :: dirfile, phase @@ -512,8 +512,8 @@ character (len=*), intent(in) :: field_name, in_field, table * subroutine fgd_alter_mplex (dirfile, field_name, in_field, count_field, - count_val, count_max) - integer, intent(in) :: dirfile, count_val, count_max + count_val, period) + integer, intent(in) :: dirfile, count_val, period character (len=*), intent(in) :: field_name, in_field, count_field * subroutine fgd_alter_multiply (dirfile, field_name, in_field1, in_field2) @@ -872,7 +872,7 @@ type gd_entry integer :: field_type, n_fields, spf, data_type, bitnum, numbits, shift integer :: fragment_index, comp_scal, poly_ord, array_len, windop - integer :: ithreshold, count_val, count_max + integer :: ithreshold, count_val, period character (len=GD_FIELD_LEN), dimension(3) :: field character (len=GD_FIELD_LEN), dimension(6) :: scalar integer, dimension(6) :: scalar_ind Modified: trunk/getdata/doc/README.idl =================================================================== --- trunk/getdata/doc/README.idl 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.idl 2013-04-06 02:17:09 UTC (rev 827) @@ -117,7 +117,6 @@ CB DCOMPLEX Array[3] BITNUM INT COMP_SCAL INT - COUNT_MAX INT COUNT_VAL INT DATA_TYPE INT DIVIDEND DOUBLE @@ -126,6 +125,7 @@ CM DCOMPLEX Array[3] N_FIELDS INT NUMBITS INT + PERIOD INT POLY_ORD INT SCALAR STRING Array[6] SCALAR_IND INT Array[6] @@ -445,7 +445,7 @@ field metadata. See gd_alter_linterp(3). PROCEDURE GD_ALTER_MPLEX, dirfile_unit, field_code, COUNT_FIELD=count_field, - COUNT_MAX=count_max, COUNT_VAL=count_val, IN_FIELD=in_field + PERIOD=period, COUNT_VAL=count_val, IN_FIELD=in_field This procedure modifies the metadata of the MPLEX field specified by 'field_code', updating only those field parameters specified as keyword Modified: trunk/getdata/doc/README.matlab =================================================================== --- trunk/getdata/doc/README.matlab 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.matlab 2013-04-06 02:17:09 UTC (rev 827) @@ -8,10 +8,10 @@ The compatibility library is installed in ${libdir}. By default, the MATLAB files are installed in ${libdir}/getdata/matlab/getdata, although this path can be changed with the --with-matlab-dir option to ./configure. To use the -bindings, the install directory must be added to the MATLAB path. +bindings, the installation directory must be added to the MATLAB path. Full documentation of the bindings are provided from within the MATLAB help -system. After installing the bindings are installed, running +system. After installing the bindings, running >> help getdata Copied: trunk/getdata/doc/README.perl (from rev 826, trunk/getdata/doc/README.perl.in) =================================================================== --- trunk/getdata/doc/README.perl (rev 0) +++ trunk/getdata/doc/README.perl 2013-04-06 02:17:09 UTC (rev 827) @@ -0,0 +1,16 @@ +PERL BINDINGS FOR GETDATA +========================= + +The Perl bindings consist of a perl module, `GetData.pm'. They should work with +Perl 5.6 or newer. Complex data are represented within the module as +Math::Complex objects. + +The GetData Perl bindings are documented in POD markup within GetData.pm. +After installation, this documentation should be available in section 3 of +the UNIX manual: + + $ man 3 GetData + +Before installation, the manual can be read using a command along the lines of + + $ pod2man bindings/perl/GetData.pm.in | nroff -mandoc | less Deleted: trunk/getdata/doc/README.perl.in =================================================================== --- trunk/getdata/doc/README.perl.in 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/doc/README.perl.in 2013-04-06 02:17:09 UTC (rev 827) @@ -1,16 +0,0 @@ -PERL BINDINGS FOR GETDATA -========================= - -The Perl bindings consist of a perl module, `GetData.pm'. They should work with -Perl 5.6 or newer. Complex data are represented within the module as -Math::Complex objects. - -The GetData Perl bindings are documented in POD markup within GetData.pm. -After installation, this documentation should be available in section @PERL_MAN3EXT@ of -the UNIX manual: - - $ man @PERL_MAN3EXT@ GetData - -Before installation, the manual can be read using a command along the lines of - - $ pod2man bindings/perl/GetData.pm.in | nroff -mandoc | less Modified: trunk/getdata/m4/perl.m4 =================================================================== --- trunk/getdata/m4/perl.m4 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/m4/perl.m4 2013-04-06 02:17:09 UTC (rev 827) @@ -177,7 +177,7 @@ GD_PERL_CONFIG([perlmandir], [siteman3direxp]) elif test $perl_inst_type != "vendor"; then perldir="${local_perl_path}" - perlmandir="${mandir}" + perlmandir="${man3dir}" fi if test $perlmandir = "UNKNOWN"; then Modified: trunk/getdata/man/dirfile-format.5 =================================================================== --- trunk/getdata/man/dirfile-format.5 2013-04-05 01:27:53 UTC (rev 826) +++ trunk/getdata/man/dirfile-format.5 2013-04-06 02:17:09 UTC (rev 827) @@ -857,12 +857,8 @@ .I period place no restrictions on values contained in .IR index . -Specifically, samples of +Specifically, particular values of .I index -may exceed -.IR period . -Particular values of -.I index (including .IR count ) need not be equally spaced (neither by @@ -871,8 +867,11 @@ .I index need not ever take on the value .I count -(in which case the value of the entirety of the output vector is -implementation dependent). MPLEX appeared in Standards Version 9. +(in which case the value of the entirety of the derived field is +implementation dependent). Different MPLEX field definitions which use the +same index vector may specify different +.IR period s. +MPLEX appeared in Standards Version 9. .RE .TP This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-05 01:27:56
|
Revision: 826 http://sourceforge.net/p/getdata/code/826 Author: ketiltrout Date: 2013-04-05 01:27:53 +0000 (Fri, 05 Apr 2013) Log Message: ----------- Fix tests. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/bindings/f77/test/big_test.f trunk/getdata/bindings/f77/test/big_test95.f90 trunk/getdata/bindings/perl/t/big_test.t Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-04-05 01:08:18 UTC (rev 825) +++ trunk/getdata/ChangeLog 2013-04-05 01:27:53 UTC (rev 826) @@ -1,4 +1,8 @@ -2013-03-13 D. V. Wiebe <ge...@ke...> svn:825 +2013-04-05 D. V. Wiebe <ge...@ke...> svn:826 + * bindings/f77/test/big_test.f bindings/f77/test/big_test95.f90 + bindings/perl/t/big_test.t: Fix test 231. + +2013-04-05 D. V. Wiebe <ge...@ke...> svn:825 * src/getdata.h.in: Renamed gd_entry_t.count_max to gd_entry_t.period. * bindings/cxx/getdata/entry.h (Entry::Period) Modified: trunk/getdata/bindings/f77/test/big_test.f =================================================================== --- trunk/getdata/bindings/f77/test/big_test.f 2013-04-05 01:08:18 UTC (rev 825) +++ trunk/getdata/bindings/f77/test/big_test.f 2013-04-05 01:27:53 UTC (rev 826) @@ -2042,7 +2042,7 @@ CALL CHKIN2(ne, 230, 7, j, 12) C 231: GDALMX check - CALL GDALMX(d, 'new21', 5, 'in3', 3, 'in4', 3, -1, 7) + CALL GDALMX(d, 'new21', 5, 'in3', 3, 'in4', 3, 7, -1) CALL CHKOK2(ne, 231, 1, d) l = flen @@ -2052,10 +2052,10 @@ CALL CHKIN2(ne, 231, 1, i, flen) CALL CHKIN2(ne, 231, 2, l, flen) CALL CHKIN2(ne, 231, 3, n, 0) - CALL CHKIN2(ne, 231, 4, m, 5) + CALL CHKIN2(ne, 231, 4, m, 7) CALL CHKST2(ne, 231, 5, fields(1), 'in3') CALL CHKST2(ne, 231, 6, fields(2), 'in4') - CALL CHKIN2(ne, 231, 7, j, 7) + CALL CHKIN2(ne, 231, 7, j, 6) C 232: GDTOKE check l = slen Modified: trunk/getdata/bindings/f77/test/big_test95.f90 =================================================================== --- trunk/getdata/bindings/f77/test/big_test95.f90 2013-04-05 01:08:18 UTC (rev 825) +++ trunk/getdata/bindings/f77/test/big_test95.f90 2013-04-05 01:27:53 UTC (rev 826) @@ -2480,17 +2480,17 @@ call check_int2(ne, 230, 6, ent%period, 12) ! 231: fgd_alter_mplex check - call fgd_alter_mplex(d, 'new21', 'in3', 'in4', -1, 7) + call fgd_alter_mplex(d, 'new21', 'in3', 'in4', 7, -1) call check_ok2(ne, 231, 1, d) n = fgd_entry(d, 'new21', ent) call check_ok2(ne, 231, 2, d) call check_int2(ne, 231, 1, n, GD_MPLEX_ENTRY) call check_int2(ne, 231, 2, ent%fragment_index, 0) - call check_int2(ne, 231, 3, ent%count_val, 5) + call check_int2(ne, 231, 3, ent%count_val, 7) call check_str2(ne, 231, 4, ent%field(1), 'in3') call check_str2(ne, 231, 5, ent%field(2), 'in4') - call check_int2(ne, 231, 6, ent%period, 7) + call check_int2(ne, 231, 6, ent%period, 6) ! 232: fgd_strtok check l = slen Modified: trunk/getdata/bindings/perl/t/big_test.t =================================================================== --- trunk/getdata/bindings/perl/t/big_test.t 2013-04-05 01:08:18 UTC (rev 825) +++ trunk/getdata/bindings/perl/t/big_test.t 2013-04-05 01:27:53 UTC (rev 826) @@ -1648,16 +1648,16 @@ CheckNum2(230, 5, $h{"period"}, 12); # 231: gd_alter_mplex check -$s = $_->alter_mplex('new21', 'in3', 'in4', -1, 7); +$s = $_->alter_mplex('new21', 'in3', 'in4', 7, -1); CheckOK2(231, 1); %h = $_->entry('new21'); CheckOK2(231, 2); CheckNum2(231, 1, $h{"field_type"}, $GetData::MPLEX_ENTRY); CheckNum2(231, 2, $h{"fragment_index"}, 0); -CheckNum2(231, 3, $h{"count_val"}, 5); +CheckNum2(231, 3, $h{"count_val"}, 7); CheckSArray2(231, 4, $h{"in_fields"}, 'in3', 'in4'); -CheckNum2(231, 5, $h{"period"}, 7); +CheckNum2(231, 5, $h{"period"}, 6); # 232: gd_strtok check @a = $_->strtok('"test1 test2" test3\ test4 test5'); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-04-05 01:08:23
|
Revision: 825 http://sourceforge.net/p/getdata/code/825 Author: ketiltrout Date: 2013-04-05 01:08:18 +0000 (Fri, 05 Apr 2013) Log Message: ----------- Fix various MPLEX bugs/inconsistencies. Modified Paths: -------------- trunk/getdata/ChangeLog trunk/getdata/NEWS trunk/getdata/bindings/cxx/getdata/entry.h trunk/getdata/bindings/cxx/getdata/mplexentry.h trunk/getdata/bindings/cxx/mplexentry.cpp trunk/getdata/bindings/cxx/test/big_test.cpp trunk/getdata/bindings/f77/fgetdata.c trunk/getdata/bindings/f77/getdata.f90.in trunk/getdata/bindings/f77/test/big_test95.f90 trunk/getdata/bindings/idl/getdata.c trunk/getdata/bindings/idl/test/big_test.pro trunk/getdata/bindings/matlab/gd_add_mplex.m trunk/getdata/bindings/matlab/gd_alter_mplex.m trunk/getdata/bindings/matlab/gd_madd_mplex.m trunk/getdata/bindings/matlab/matlab.c trunk/getdata/bindings/matlab/test/big_test.m trunk/getdata/bindings/perl/GetData.xs trunk/getdata/bindings/perl/simple_funcs.xsin trunk/getdata/bindings/perl/t/big_test.t trunk/getdata/bindings/python/pyentry.c trunk/getdata/bindings/python/test/big_test.py trunk/getdata/man/dirfile-format.5 trunk/getdata/man/gd_add_bit.3 trunk/getdata/man/gd_alter_bit.3 trunk/getdata/man/gd_cbopen.3 trunk/getdata/man/gd_entry.3 trunk/getdata/man/gd_madd_bit.3 trunk/getdata/man/gd_mplex_lookback.3 trunk/getdata/src/add.c trunk/getdata/src/del.c trunk/getdata/src/entry.c trunk/getdata/src/errors.c trunk/getdata/src/flush.c trunk/getdata/src/getdata.c trunk/getdata/src/getdata.h.in trunk/getdata/src/internal.h trunk/getdata/src/legacy.c trunk/getdata/src/mod.c trunk/getdata/src/parse.c trunk/getdata/test/add_mplex.c trunk/getdata/test/add_mplex_val.c trunk/getdata/test/entry_mplex.c trunk/getdata/test/entry_mplex_scalar.c trunk/getdata/test/madd_mplex.c trunk/getdata/test/parse_mplex_nomax.c trunk/getdata/test/seek_neg.c trunk/getdata/test/tok_arg.c Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/ChangeLog 2013-04-05 01:08:18 UTC (rev 825) @@ -1,3 +1,40 @@ +2013-03-13 D. V. Wiebe <ge...@ke...> svn:825 + * src/getdata.h.in: Renamed gd_entry_t.count_max to gd_entry_t.period. + + * bindings/cxx/getdata/entry.h (Entry::Period) + bindings/cxx/getdata/mplexentry.h (NplexEntry::Period): Renamed from CountMax. + * bindings/cxx/mplexentry.cpp (MplexEntry::SetPeriod): Renamed from + SetCountMax. + * bindings/cxx/mplexentry.cpp (MplexEntry::MplexEntry) + bindings/f77/fgetdata.c (GDGEMX) bindings/f77/getdata.f90.in (fgd_entry + fgd_add fgd_madd fgd_alter_entry fgd_add_mplex fgd_madd_mplex + fgd_alter_mplex) bindings/idl/getdata.c (gdidl_make_idl_entry + gdidl_alter_mplex) bindings/matlab/gd_add_mplex.m + bindings/matlab/gd_alter_mplex.m bindings/matlab/gd_madd_mplex.m + bindings/matlab/matlab.c (gdmx_from_entry gdmx_to_entry) + bindings/perl/GetData.xs (gdp_to_entry entry) bindings/python/pyentry.c + (gdpy_set_entry_from_tuple gdpy_entry_getperiod gdpy_entry_setperiod + gdpy_entry_getparms): Rename count_max to period. + + * src/add.c (_GD_Add): Fix range checks on MPLEX parameters. + + * src/getdata.c (_GD_DoMplex): The default period is 2n+1, not 2n. + + * src/internal.h: Rename GD_E_ENTRY_CNTMAX to GD_E_ENTRY_PERIOD. + * src/errors.c: Update GD_E_ENTRY_PERIOD and GD_E_FORMAT_MPLEXVAL messages. + + * src/mod.c (_GD_Change): mplex.count_val = -1 is not a magic value. + + * src/parse.c (_GD_ParseMplex): Remove incorrect restrictions count_val <= + period and count_val >= 0. + + * bindings/idl/getdata.c (gdidl_read_idl_entry): Properly convert an IDL + MPLEX entry object. + + * bindings/idl/getdata.c (gdidl_alter_mplex): Handle missing COUNT_VAL. + + * man/dirfile-format.5: Fix and clarify MPLEX specification. + 2013-03-13 D. V. Wiebe <ge...@ke...> svn:819 * src/flush.c (_GD_FlushFragment): Strip affixes from field codes in /REFERENCE directives. Modified: trunk/getdata/NEWS =================================================================== --- trunk/getdata/NEWS 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/NEWS 2013-04-05 01:08:18 UTC (rev 825) @@ -2,6 +2,27 @@ Library Changes: + * BUG FIX: Inconsistant behaviour in the library, coupled with contradictory + statements in the Dirfile Standards, has resulted in confusion over the + meaning of the final, optional, parameter in a MPLEX definition. To be clear: + this parameter is simply the expected period between successive occurances of + the mplex value in the index vector. It is used by GetData only to figure out + a resonable length of the MPLEX lookback. To help reduce confusion, this + parameter has been renamed from "count_max" to "period". The Standards have + also been clarified. See also the following related bug fixes. + + * BUG FIX: The count_val MPLEX parameter is not restricted to non-negative + numbers. + + * BUG FIX: The optional period (formerly count_max) MPLEX parameter does not + restrict allowed values of the count_val parameter. + + * BUG FIX: The default MPLEX period, if none is specified, is 2*count_val + 1, + not simply 2 * count_val, when count_val is greater than 5. + + * BUG FIX: A count_val of -1 in gd_alter_entry or gd_[m]alter_mplex calls is + not a special value: it just sets the count_val to -1. + * BUG FIX: Trying to position an I/O pointer to before sample zero with gd_seek() now properly fails. Previously it would allow it, causing bizarre things to happen later. @@ -22,6 +43,10 @@ Bindings Changes: + * IDL BUG FIX: Entry structs representing MPLEX fields are now properly + interpreted. Previously, the underlying gd_entry_t object was being + incorrectly initialised. + * PYTHON BUG FIX: Numpy arrays returned by dirfile.getdata() are now the correct length. Previously they would always be the length requested (or the length of the dirfile, if no length was explicitly given) even if fewer Modified: trunk/getdata/bindings/cxx/getdata/entry.h =================================================================== --- trunk/getdata/bindings/cxx/getdata/entry.h 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/cxx/getdata/entry.h 2013-04-05 01:08:18 UTC (rev 825) @@ -224,8 +224,8 @@ return (E.field_type == GD_MPLEX_ENTRY) ? E.u.mplex.count_val : 0; } - virtual int CountMax() const { - return (E.field_type == GD_MPLEX_ENTRY) ? E.u.mplex.count_max : 0; + virtual int Period() const { + return (E.field_type == GD_MPLEX_ENTRY) ? E.u.mplex.period : 0; } /* Set methods */ Modified: trunk/getdata/bindings/cxx/getdata/mplexentry.h =================================================================== --- trunk/getdata/bindings/cxx/getdata/mplexentry.h 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/cxx/getdata/mplexentry.h 2013-04-05 01:08:18 UTC (rev 825) @@ -35,7 +35,7 @@ MplexEntry() : Entry() { E.field_type = GD_MPLEX_ENTRY; }; MplexEntry(const char* field_code, const char* in_field, - const char *check_Field, int count_val, int count_max, + const char *check_field, int count_val, int period, int fragment_index = 0); virtual const char *Input(int index = 0) const { @@ -48,13 +48,13 @@ virtual int CountVal() const { return E.u.mplex.count_val; }; - virtual int CountMax() const { return E.u.mplex.count_max; }; + virtual int Period() const { return E.u.mplex.period; }; int SetInput(const char* field, int index); virtual int SetCountVal(int count_val); virtual int SetCountVal(const char* count_val); - virtual int SetCountMax(int count_max); - virtual int SetCountMax(const char* count_max); + virtual int SetPeriod(int period); + virtual int SetPeriod(const char* period); private: MplexEntry(const GetData::Dirfile *dirfile, const char* field_code) : Modified: trunk/getdata/bindings/cxx/mplexentry.cpp =================================================================== --- trunk/getdata/bindings/cxx/mplexentry.cpp 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/cxx/mplexentry.cpp 2013-04-05 01:08:18 UTC (rev 825) @@ -21,11 +21,10 @@ #include "internal.h" MplexEntry::MplexEntry(const char* field_code, const char* in_field, - const char* count, int count_val, int count_max, - int fragment_index) : Entry() + const char* count, int count_val, int period, int fragment_index) : Entry() { dtrace("\"%s\", \"%s\", \"%s\", %i, %i, %i", field_code, - in_field, count, count_val, count_max, fragment_index); + in_field, count, count_val, period, fragment_index); E.field = strdup(field_code); E.field_type = GD_MPLEX_ENTRY; @@ -33,7 +32,7 @@ E.in_fields[1] = strdup(count); E.scalar[0] = E.scalar[1] = 0; E.u.mplex.count_val = count_val; - E.u.mplex.count_max = count_max; + E.u.mplex.period = period; E.fragment_index = fragment_index; dreturnvoid(); @@ -73,13 +72,13 @@ return ret; } -int MplexEntry::SetCountMax(int count_max) +int MplexEntry::SetPeriod(int period) { int ret = 0; - dtrace("%u", count_max); + dtrace("%u", period); - E.u.mplex.count_max = count_max; + E.u.mplex.period = period; if (D != NULL) ret = gd_alter_entry(D->D, E.field, &E, 0); @@ -107,19 +106,19 @@ return r; } -int MplexEntry::SetCountMax(const char *count_max) +int MplexEntry::SetPeriod(const char *period) { int r = 0; - dtrace("\"%s\"", count_max); + dtrace("\"%s\"", period); - SetScalar(1, count_max); + SetScalar(1, period); if (D != NULL) { r = gd_alter_entry(D->D, E.field, &E, 0); if (!r) - r = gd_get_constant(D->D, count_max, GD_UINT16, &E.u.mplex.count_max); + r = gd_get_constant(D->D, period, GD_UINT16, &E.u.mplex.period); } dreturn("%i", r); Modified: trunk/getdata/bindings/cxx/test/big_test.cpp =================================================================== --- trunk/getdata/bindings/cxx/test/big_test.cpp 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/cxx/test/big_test.cpp 2013-04-05 01:08:18 UTC (rev 825) @@ -1617,7 +1617,7 @@ CHECK_INT2(228, 3, ent->CountVal(), 1); CHECK_STRING2(228, 4, ent->Input(0), "data"); CHECK_STRING2(228, 5, ent->Input(1), "sbit"); - CHECK_INT2(228, 6, ent->CountMax(), 10); + CHECK_INT2(228, 6, ent->Period(), 10); delete ent; // 229: Dirfile::Add / MplexEntry check @@ -1626,7 +1626,7 @@ xent.SetInput("in1", 0); xent.SetInput("in2", 1); xent.SetCountVal(5); - xent.SetCountMax(6); + xent.SetPeriod(6); d->Add(xent); CHECK_OK2(229, 1); @@ -1637,7 +1637,7 @@ CHECK_INT2(229, 3, ent->CountVal(), 5); CHECK_STRING2(229, 4, ent->Input(0), "in1"); CHECK_STRING2(229, 5, ent->Input(1), "in2"); - CHECK_INT2(229, 6, ent->CountMax(), 6); + CHECK_INT2(229, 6, ent->Period(), 6); delete ent; // 230: gd_madd_mplex check @@ -1646,7 +1646,7 @@ xent.SetInput("in2", 0); xent.SetInput("in3", 1); xent.SetCountVal(0); - xent.SetCountMax(12); + xent.SetPeriod(12); d->MAdd(xent, "data"); CHECK_OK2(230, 1); @@ -1657,7 +1657,7 @@ CHECK_INT2(230, 3, ent->CountVal(), 0); CHECK_STRING2(230, 4, ent->Input(0), "in2"); CHECK_STRING2(230, 5, ent->Input(1), "in3"); - CHECK_INT2(230, 6, ent->CountMax(), 12); + CHECK_INT2(230, 6, ent->Period(), 12); delete ent; // 231: gd_alter_mplex check @@ -1665,7 +1665,7 @@ xep->SetInput("in3", 0); xep->SetInput("in4", 1); xep->SetCountVal(3); - xep->SetCountMax(7); + xep->SetPeriod(7); CHECK_OK2(231, 1); delete xep; @@ -1676,7 +1676,7 @@ CHECK_INT2(231, 3, ent->CountVal(), 3); CHECK_STRING2(231, 4, ent->Input(0), "in3"); CHECK_STRING2(231, 5, ent->Input(1), "in4"); - CHECK_INT2(231, 6, ent->CountMax(), 7); + CHECK_INT2(231, 6, ent->Period(), 7); delete ent; // 232: gd_tokenise Modified: trunk/getdata/bindings/f77/fgetdata.c =================================================================== --- trunk/getdata/bindings/f77/fgetdata.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/f77/fgetdata.c 2013-04-05 01:08:18 UTC (rev 825) @@ -886,7 +886,7 @@ /* gd_entry wrapper for MPLEX */ void F77_FUNC(gdgemx, GDGEMX) (char *in_field, int32_t *in_field_l, - char *count_field, int32_t *count_field_l, int32_t *val, int32_t *max, + char *count_field, int32_t *count_field_l, int32_t *val, int32_t *period, int32_t *fragment_index, const int32_t *dirfile, const char *field_code, const int32_t *field_code_l) { @@ -894,7 +894,7 @@ gd_entry_t E; dtrace("%p, %i, %p, %i, %p, %p, %p, %i, %p, %i", in_field, *in_field_l, - count_field, *count_field_l, val, max, fragment_index, *dirfile, + count_field, *count_field_l, val, period, fragment_index, *dirfile, field_code, *field_code_l); if (gd_entry(_GDF_GetDirfile(*dirfile), _GDF_CString(&fc, field_code, @@ -904,7 +904,7 @@ _GDF_FString(in_field, in_field_l, E.in_fields[0]); _GDF_FString(count_field, count_field_l, E.in_fields[1]); *val = E.EN(mplex,count_val); - *max = E.EN(mplex,count_max); + *period = E.EN(mplex,period); *fragment_index = E.fragment_index; gd_free_entry_strings(&E); } Modified: trunk/getdata/bindings/f77/getdata.f90.in =================================================================== --- trunk/getdata/bindings/f77/getdata.f90.in 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/f77/getdata.f90.in 2013-04-05 01:08:18 UTC (rev 825) @@ -30,7 +30,7 @@ type gd_entry integer :: field_type, n_fields, spf, data_type, bitnum, numbits, shift integer :: fragment_index, comp_scal, poly_ord, array_len, windop, ithreshold - integer :: count_val, count_max + integer :: count_val, period character (len=GD_FIELD_LEN), dimension(3) :: field character (len=GD_FIELD_LEN), dimension(6) :: scalar integer, dimension(6) :: scalar_ind @@ -906,7 +906,7 @@ else if (fgd_entry .EQ. GD_MPLEX_ENTRY) then ! mplex call gdgemx(ent%field(1), len1, ent%field(2), len2, ent%count_val, & - ent%count_max, ent%fragment_index, dirfile, TRIM(field_code), & + ent%period, ent%fragment_index, dirfile, TRIM(field_code), & LEN_TRIM(field_code)) len1 = GD_FIELD_LEN @@ -1035,7 +1035,7 @@ else if (ent%field_type .EQ. GD_MPLEX_ENTRY) then call gdadmx(dirfile, TRIM(field_code), LEN_TRIM(field_code), & TRIM(ent%field(1)), LEN_TRIM(ent%field(1)), TRIM(ent%field(2)), & - LEN_TRIM(ent%field(2)), ent%count_val, ent%count_max, ent%fragment_index) + LEN_TRIM(ent%field(2)), ent%count_val, ent%period, ent%fragment_index) else if (ent%field_type .EQ. GD_CONST_ENTRY) then call gdadco(dirfile, TRIM(field_code), LEN_TRIM(field_code), & ent%data_type, GD_INT32, zero, ent%fragment_index) @@ -1279,7 +1279,7 @@ else if (ent%field_type .EQ. GD_MPLEX_ENTRY) then call gdmdmx(dirfile, TRIM(parent), LEN_TRIM(parent), TRIM(field_code), & LEN_TRIM(field_code), TRIM(ent%field(1)), LEN_TRIM(ent%field(1)), & - TRIM(ent%field(2)), LEN_TRIM(ent%field(2)), ent%count_val, ent%count_max) + TRIM(ent%field(2)), LEN_TRIM(ent%field(2)), ent%count_val, ent%period) else if (ent%field_type .EQ. GD_CONST_ENTRY) then call gdmdco(dirfile, TRIM(parent), LEN_TRIM(parent), TRIM(field_code), & LEN_TRIM(field_code), ent%data_type, GD_INT32, zero) @@ -1664,7 +1664,7 @@ else if (ent%field_type .EQ. GD_CONST_ENTRY) then call gdalmx(dirfile, TRIM(field_code), LEN_TRIM(field_code), & TRIM(ent%field(1)), LEN_TRIM(ent%field(1)), TRIM(ent%field(2)), & - LEN_TRIM(ent%field(2)), ent%count_val, ent%count_max, ent%fragment_index) + LEN_TRIM(ent%field(2)), ent%count_val, ent%period, ent%fragment_index) else if (ent%field_type .EQ. GD_CONST_ENTRY) then call gdalco(dirfile, TRIM(field_code), LEN_TRIM(field_code), ent%data_type) else if (ent%field_type .EQ. GD_CARRAY_ENTRY) then @@ -2751,33 +2751,33 @@ end subroutine subroutine fgd_add_mplex (dirfile, field_code, in_field, count_field, & - count_val, count_max, fragment_index) + count_val, period, fragment_index) character(len=*), intent(in) :: field_code, in_field, count_field - integer, intent(in) :: dirfile, count_val, count_max, fragment_index + integer, intent(in) :: dirfile, count_val, period, fragment_index call gdadmx(dirfile, TRIM(field_code), LEN_TRIM(field_code), TRIM(in_field), & LEN_TRIM(in_field), TRIM(count_field), LEN_TRIM(count_field), count_val, & - count_max, fragment_index) + period, fragment_index) end subroutine subroutine fgd_madd_mplex (dirfile, parent, field_code, in_field, count_field, & - count_val, count_max) + count_val, period) character(len=*), intent(in) :: parent, field_code, in_field, count_field - integer, intent(in) :: dirfile, count_val, count_max + integer, intent(in) :: dirfile, count_val, period call gdmdmx(dirfile, TRIM(parent), LEN_TRIM(parent), TRIM(field_code), & LEN_TRIM(field_code), TRIM(in_field), LEN_TRIM(in_field), TRIM(count_field), & - LEN_TRIM(count_field), count_val, count_max) + LEN_TRIM(count_field), count_val, period) end subroutine subroutine fgd_alter_mplex (dirfile, field_name, in_field, count_field, & - count_val, count_max) - integer, intent(in) :: dirfile, count_val, count_max + count_val, period) + integer, intent(in) :: dirfile, count_val, period character (len=*), intent(in) :: field_name, in_field, count_field call gdalmx(dirfile, TRIM(field_name), LEN_TRIM(field_name), TRIM(in_field), & LEN_TRIM(in_field), TRIM(count_field), LEN_TRIM(count_field), count_val, & - count_max) + period) end subroutine subroutine fgd_strtok (token, l, dirfile, string) Modified: trunk/getdata/bindings/f77/test/big_test95.f90 =================================================================== --- trunk/getdata/bindings/f77/test/big_test95.f90 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/f77/test/big_test95.f90 2013-04-05 01:08:18 UTC (rev 825) @@ -2451,7 +2451,7 @@ call check_int2(ne, 228, 3, ent%count_val, 1) call check_str2(ne, 228, 4, ent%field(1), 'data') call check_str2(ne, 228, 5, ent%field(2), 'sbit') - call check_int2(ne, 228, 6, ent%count_max, 10) + call check_int2(ne, 228, 6, ent%period, 10) ! 229: fgd_add_mplex check call fgd_add_mplex(d, 'new21', 'in1', 'in2', 5, 6, 0) @@ -2464,7 +2464,7 @@ call check_int2(ne, 229, 3, ent%count_val, 5) call check_str2(ne, 229, 4, ent%field(1), 'in1') call check_str2(ne, 229, 5, ent%field(2), 'in2') - call check_int2(ne, 229, 6, ent%count_max, 6) + call check_int2(ne, 229, 6, ent%period, 6) ! 230: fgd_madd_mplex check call fgd_madd_mplex(d, 'data', 'mnew21', 'in2', 'in3', 0, 12) @@ -2477,7 +2477,7 @@ call check_int2(ne, 230, 3, ent%count_val, 0) call check_str2(ne, 230, 4, ent%field(1), 'in2') call check_str2(ne, 230, 5, ent%field(2), 'in3') - call check_int2(ne, 230, 6, ent%count_max, 12) + call check_int2(ne, 230, 6, ent%period, 12) ! 231: fgd_alter_mplex check call fgd_alter_mplex(d, 'new21', 'in3', 'in4', -1, 7) @@ -2490,7 +2490,7 @@ call check_int2(ne, 231, 3, ent%count_val, 5) call check_str2(ne, 231, 4, ent%field(1), 'in3') call check_str2(ne, 231, 5, ent%field(2), 'in4') - call check_int2(ne, 231, 6, ent%count_max, 7) + call check_int2(ne, 231, 6, ent%period, 7) ! 232: fgd_strtok check l = slen Modified: trunk/getdata/bindings/idl/getdata.c =================================================================== --- trunk/getdata/bindings/idl/getdata.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/idl/getdata.c 2013-04-05 01:08:18 UTC (rev 825) @@ -593,7 +593,7 @@ *(IDL_INT*)(data + IDL_StructTagInfoByName(gdidl_entry_def, "COUNT_VAL", IDL_MSG_LONGJMP, NULL)) = E->count_val; *(IDL_INT*)(data + IDL_StructTagInfoByName(gdidl_entry_def, - "COUNT_MAX", IDL_MSG_LONGJMP, NULL)) = E->count_max; + "PERIOD", IDL_MSG_LONGJMP, NULL)) = E->period; IDL_StrStore((IDL_STRING*)(data + IDL_StructTagInfoByName(gdidl_entry_def, "SCALAR", IDL_MSG_LONGJMP, NULL)), E->scalar[0]); @@ -668,7 +668,8 @@ if (E->field_type == GD_BIT_ENTRY || E->field_type == GD_LINTERP_ENTRY || E->field_type == GD_MULTIPLY_ENTRY || E->field_type == GD_PHASE_ENTRY || E->field_type == GD_SBIT_ENTRY || E->field_type == GD_POLYNOM_ENTRY - || E->field_type == GD_DIVIDE_ENTRY || E->field_type == GD_RECIP_ENTRY) + || E->field_type == GD_DIVIDE_ENTRY || E->field_type == GD_RECIP_ENTRY + || E->field_type == GD_MPLEX_ENTRY || E->field_type == GD_WINDOW_ENTRY) { o = IDL_StructTagInfoByName(v->value.s.sdef, "IN_FIELDS", action, &d); if (o != -1) { @@ -974,16 +975,16 @@ if (o != -1) { if (d->type != IDL_TYP_INT) idl_abort("GD_ENTRY element COUNT_VAL must be of type INT"); - E->bitnum = *(int16_t*)(data + o); - } else - E->bitnum = -1; + E->count_val = *(int16_t*)(data + o); + } - o = IDL_StructTagInfoByName(v->value.s.sdef, "COUNT_MAX", action, &d); + o = IDL_StructTagInfoByName(v->value.s.sdef, "PERIOD", action, &d); if (o != -1) { if (d->type != IDL_TYP_INT) - idl_abort("GD_ENTRY element COUNT_MAX must be of type INT"); - E->numbits = *(int16_t*)(data + o); - } + idl_abort("GD_ENTRY element PERIOD must be of type INT"); + E->period = *(int16_t*)(data + o); + } else + E->period = -1; copy_scalar[0] = copy_scalar[1] = 1; break; @@ -5317,7 +5318,7 @@ typedef struct { IDL_KW_RESULT_FIRST_FIELD; GDIDL_KW_RESULT_ERROR; - int val, max; + int val, val_x, period; IDL_STRING in_field1; int in_field1_x; IDL_STRING in_field2; @@ -5325,20 +5326,20 @@ } KW_RESULT; KW_RESULT kw; - kw.in_field1_x = kw.in_field2_x = 0; - kw.val = -1; - kw.max = -1; + kw.in_field1_x = kw.in_field2_x = kw.val_x = 0; + kw.period = -1; GDIDL_KW_INIT_ERROR; static IDL_KW_PAR kw_pars[] = { { "COUNT_FIELD", IDL_TYP_STRING, 1, 0, IDL_KW_OFFSETOF(in_field2_x), IDL_KW_OFFSETOF(in_field2) }, - { "COUNT_MAX", IDL_TYP_INT, 1, 0, 0, IDL_KW_OFFSETOF(max) }, - { "COUNT_VAL", IDL_TYP_INT, 1, 0, 0, IDL_KW_OFFSETOF(val) }, + { "COUNT_VAL", IDL_TYP_INT, 1, 0, IDL_KW_OFFSETOF(val_x), + IDL_KW_OFFSETOF(val) }, GDIDL_KW_PAR_ERROR, GDIDL_KW_PAR_ESTRING, { "IN_FIELD", IDL_TYP_STRING, 1, 0, IDL_KW_OFFSETOF(in_field1_x), IDL_KW_OFFSETOF(in_field1) }, + { "PERIOD", IDL_TYP_INT, 1, 0, 0, IDL_KW_OFFSETOF(period) }, { NULL } }; @@ -5347,14 +5348,23 @@ DIRFILE* D = gdidl_get_dirfile(IDL_LongScalar(argv[0])); const char* field_code = IDL_VarGetString(argv[1]); - if (kw.in_field1_x) - in_field1 = IDL_STRING_STR(&kw.in_field1); + /* no value specified, figure out the previous value */ + if (!kw.val_x) { + gd_entry_t E; + gd_entry(D, field_code, &E); + kw.val = E.count_val; + } - if (kw.in_field2_x) - in_field2 = IDL_STRING_STR(&kw.in_field2); + if (!gd_error(D)) { + if (kw.in_field1_x) + in_field1 = IDL_STRING_STR(&kw.in_field1); - gd_alter_mplex(D, field_code, in_field1, in_field2, kw.val, kw.max); + if (kw.in_field2_x) + in_field2 = IDL_STRING_STR(&kw.in_field2); + gd_alter_mplex(D, field_code, in_field1, in_field2, kw.val, kw.period); + } + GDIDL_SET_ERROR(D); IDL_KW_FREE; @@ -5855,7 +5865,6 @@ { "CB", lincom_dims, (void*)IDL_TYP_DCOMPLEX }, /* LINCOM */ { "BITNUM", 0, (void*)IDL_TYP_INT }, /* (S)BIT */ { "COMP_SCAL", 0, (void*)IDL_TYP_INT }, /* LINCOM / POLYNOM */ - { "COUNT_MAX", 0, (void*)IDL_TYP_INT }, /* MPLEX */ { "COUNT_VAL", 0, (void*)IDL_TYP_INT }, /* MPLEX */ { "DATA_TYPE", 0, (void*)IDL_TYP_INT }, /* RAW / CONST / CARRAY */ { "DIVIDEND", 0, (void*)IDL_TYP_DOUBLE }, /* RECIP */ @@ -5864,6 +5873,7 @@ { "CM", lincom_dims, (void*)IDL_TYP_DCOMPLEX }, /* LINCOM */ { "N_FIELDS", 0, (void*)IDL_TYP_INT }, /* LINCOM */ { "NUMBITS", 0, (void*)IDL_TYP_INT }, /* (S)BIT */ + { "PERIOD", 0, (void*)IDL_TYP_INT }, /* MPLEX */ { "POLY_ORD", 0, (void*)IDL_TYP_INT }, /* POLYNOM */ { "SCALAR", polynom_dims, (void*)IDL_TYP_STRING }, { "SCALAR_IND", polynom_dims, (void*)IDL_TYP_INT }, Modified: trunk/getdata/bindings/idl/test/big_test.pro =================================================================== --- trunk/getdata/bindings/idl/test/big_test.pro 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/idl/test/big_test.pro 2013-04-05 01:08:18 UTC (rev 825) @@ -1295,7 +1295,7 @@ nume += check_simple2(228, 2, n.fragment, 0) nume += check_simple2(228, 3, n.count_val, 1) nume += check_simple2(228, 4, n.in_fields, [ 'data', 'sbit' ]) -nume += check_simple2(228, 5, n.count_max, 10) +nume += check_simple2(228, 5, n.period, 10) ; 229: gd_add_mplex check gd_add_mplex, d, 'new21', 'in1', 'in2', 5, max=6 @@ -1307,7 +1307,7 @@ nume += check_simple2(229, 2, n.fragment, 0) nume += check_simple2(229, 3, n.count_val, 5) nume += check_simple2(229, 4, n.in_fields, [ 'in1', 'in2' ]) -nume += check_simple2(229, 5, n.count_max, 6) +nume += check_simple2(229, 5, n.period, 6) ; 230: gd_madd_mplex check gd_add_mplex, d, parent='data', 'mnew21', 'in2', 'in3', 0, max=12 @@ -1319,11 +1319,11 @@ nume += check_simple2(230, 2, n.fragment, 0) nume += check_simple2(230, 3, n.count_val, 0) nume += check_simple2(230, 4, n.in_fields, [ 'in2', 'in3' ]) -nume += check_simple2(230, 5, n.count_max, 12) +nume += check_simple2(230, 5, n.period, 12) ; 231: gd_alter_mplex check gd_alter_mplex, d, 'new21', in_field='in3', count_field='in4', count_val=2, $ - count_max=7 + period=7 nume += check_ok2(231, 1, d) n = gd_entry(d, 'new21') @@ -1332,7 +1332,7 @@ nume += check_simple2(231, 2, n.fragment, 0) nume += check_simple2(231, 3, n.count_val, 2) nume += check_simple2(231, 4, n.in_fields, [ 'in3', 'in4' ]) -nume += check_simple2(231, 5, n.count_max, 7) +nume += check_simple2(231, 5, n.period, 7) ; 232: gd_strtok check str = gd_strtok(d, STRING='"test1 test2" test3\ test4') Modified: trunk/getdata/bindings/matlab/gd_add_mplex.m =================================================================== --- trunk/getdata/bindings/matlab/gd_add_mplex.m 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/matlab/gd_add_mplex.m 2013-04-05 01:08:18 UTC (rev 825) @@ -1,5 +1,5 @@ function gd_add_mplex(D, field_code, in_field1, in_field2, count_val, ... -count_max, fragment_index) +period, fragment_index) % GD_ADD_MPLEX Add a MPLEX field % % GD_ADD_MPLEX(DIRFILE,NAME,INPUT1,INPUT2,COUNT_VAL,COUNT_MAX,FRAGMENT) @@ -19,7 +19,7 @@ GD = getdata_constants(); gd_add(D, struct('field', field_code, 'field_type', GD.MPLEX_ENTRY, ... 'fragment_index', fragment_index, 'in_fields', {{in_field1; in_field2}}, ... - 'count_val', count_val, 'count_max', count_max)); + 'count_val', count_val, 'period', period)); end % Copyright (C) 2013 D. V. Wiebe Modified: trunk/getdata/bindings/matlab/gd_alter_mplex.m =================================================================== --- trunk/getdata/bindings/matlab/gd_alter_mplex.m 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/matlab/gd_alter_mplex.m 2013-04-05 01:08:18 UTC (rev 825) @@ -1,4 +1,4 @@ -function gd_alter_mplex(D, field_code, in1, in2, count_val, count_max) +function gd_alter_mplex(D, field_code, in1, in2, count_val, period) % GD_ALTER_MPLEX Modify the metadata of a MPLEX field % % GD_ALTER_MPLEX(DIRFILE,NAME,INPUT1,INPUT2,COUNT_VAL,COUNT_MAX) @@ -17,7 +17,7 @@ GD = getdata_constants(); gd_alter_entry(D, field_code, struct('field_type', GD.MPLEX_ENTRY, ... 'in_fields', {{in1; in2}}, 'count_val', count_val, ... - 'count_max', count_max), 0); + 'period', period), 0); end % Copyright (C) 2013 D. V. Wiebe Modified: trunk/getdata/bindings/matlab/gd_madd_mplex.m =================================================================== --- trunk/getdata/bindings/matlab/gd_madd_mplex.m 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/matlab/gd_madd_mplex.m 2013-04-05 01:08:18 UTC (rev 825) @@ -1,5 +1,5 @@ function gd_madd_mplex(D, parent, field_code, in_field1, in_field2, ... -count_val, count_max) +count_val, period) % GD_MADD_MPLEX Add a MPLEX metafield % % GD_MADD_MPLEX(DIRFILE,PARENT,NAME,INPUT1,INPUT2,COUNT_VAL,COUNT_MAX) @@ -18,7 +18,7 @@ GD = getdata_constants(); gd_madd(D, struct('field', field_code, 'field_type', GD.MPLEX_ENTRY, ... 'in_fields', {{in_field1; in_field2}}, 'count_val', count_val, ... - 'count_max', count_max), parent); + 'period', period), parent); end % Copyright (C) 2013 D. V. Wiebe Modified: trunk/getdata/bindings/matlab/matlab.c =================================================================== --- trunk/getdata/bindings/matlab/matlab.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/matlab/matlab.c 2013-04-05 01:08:18 UTC (rev 825) @@ -843,7 +843,7 @@ const char *linterp_fields[] = {GDMX_COMMON_FIELDS, "in_fields", "table"}; const int mplex_nfields = GDMX_NSCALAR + 3; const char *mplex_fields[] = {GDMX_COMMON_FIELDS, "in_fields", "count_val", - "count_max", GDMX_SCALAR_FIELDS}; + "period", GDMX_SCALAR_FIELDS}; const int multiply_nfields = 1; const char *multiply_fields[] = {GDMX_COMMON_FIELDS, "in_fields"}; const int phase_nfields = GDMX_NSCALAR + 2; @@ -975,7 +975,7 @@ mxSetField(lhs, 0, "in_fields", gdmx_from_nstring_list((const char**)E->in_fields, 2)); mxSetField(lhs, 0, "count_val", gdmx_from_int(E->EN(mplex,count_val))); - mxSetField(lhs, 0, "count_max", gdmx_from_int(E->EN(mplex,count_max))); + mxSetField(lhs, 0, "period", gdmx_from_int(E->EN(mplex,period))); nscalar = 2; break; case GD_MULTIPLY_ENTRY: @@ -1299,8 +1299,8 @@ gdmx_convert_in_fields(rhs[n], &ctx, E); gdmx_convert_struct_scalar(rhs[n], &ctx, "count_val", GD_INT_TYPE, &E->EN(mplex,count_val)); - gdmx_convert_struct_scalar(rhs[n], &ctx, "count_max", GD_INT_TYPE, - &E->EN(mplex,count_max)); + gdmx_convert_struct_scalar(rhs[n], &ctx, "period", GD_INT_TYPE, + &E->EN(mplex,period)); break; case GD_PHASE_ENTRY: gdmx_convert_in_fields(rhs[n], &ctx, E); Modified: trunk/getdata/bindings/matlab/test/big_test.m =================================================================== --- trunk/getdata/bindings/matlab/test/big_test.m 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/matlab/test/big_test.m 2013-04-05 01:08:18 UTC (rev 825) @@ -1866,7 +1866,7 @@ ne = ne + check_num2(228, 3, d.fragment_index, 0); ne = ne + check_sarray2(228, 4, d.in_fields, { 'data'; 'sbit' }); ne = ne + check_num2(228, 5, d.count_val, 1); - ne = ne + check_num2(228, 6, d.count_max, 10); + ne = ne + check_num2(228, 6, d.period, 10); catch exc ne = ne + check_ok(exc, 228); end @@ -1885,7 +1885,7 @@ ne = ne + check_num2(229, 3, d.fragment_index, 0); ne = ne + check_sarray2(229, 4, d.in_fields, { 'in1'; 'in2' }); ne = ne + check_num2(229, 5, d.count_val, 5); - ne = ne + check_num2(229, 6, d.count_max, 6); + ne = ne + check_num2(229, 6, d.period, 6); catch exc ne = ne + check_ok2(exc, 229, 2); end @@ -1904,7 +1904,7 @@ ne = ne + check_num2(230, 3, d.fragment_index, 0); ne = ne + check_sarray2(230, 4, d.in_fields, { 'in3'; 'in2' }); ne = ne + check_num2(230, 5, d.count_val, 0); - ne = ne + check_num2(230, 6, d.count_max, 12); + ne = ne + check_num2(230, 6, d.period, 12); catch exc ne = ne + check_ok2(exc, 230, 2); end @@ -1923,7 +1923,7 @@ ne = ne + check_num2(231, 3, d.fragment_index, 0); ne = ne + check_sarray2(231, 4, d.in_fields, { 'in4'; 'in2' }); ne = ne + check_num2(231, 5, d.count_val, 3); - ne = ne + check_num2(231, 6, d.count_max, 7); + ne = ne + check_num2(231, 6, d.period, 7); catch exc ne = ne + check_ok2(exc, 231, 2); end Modified: trunk/getdata/bindings/perl/GetData.xs =================================================================== --- trunk/getdata/bindings/perl/GetData.xs 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/perl/GetData.xs 2013-04-05 01:08:18 UTC (rev 825) @@ -359,7 +359,7 @@ case GD_MPLEX_ENTRY: gdp_fetch_in_fields(E->in_fields, sv, 2, pkg, func); GDP_EHASH_FETCH_UV("count_val", EN(mplex,count_val), int); - GDP_EHASH_FETCH_UV("count_max", EN(mplex,count_max), int); + GDP_EHASH_FETCH_UV("period", EN(mplex,period), int); gdp_fetch_scalars(E, (HV*)sv, 0x3, pkg, func); break; case GD_RAW_ENTRY: @@ -1243,8 +1243,8 @@ GDP_PUSHrvavpv(E.in_fields, 2); GDP_PUSHpvn("count_val"); GDP_PUSHuv(E.EN(mplex,count_val)); - GDP_PUSHpvn("count_max"); - GDP_PUSHuv(E.EN(mplex,count_max)); + GDP_PUSHpvn("period"); + GDP_PUSHuv(E.EN(mplex,period)); sp = gdp_store_scalars(sp, &E, 0x3); break; case GD_INDEX_ENTRY: Modified: trunk/getdata/bindings/perl/simple_funcs.xsin =================================================================== --- trunk/getdata/bindings/perl/simple_funcs.xsin 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/perl/simple_funcs.xsin 2013-04-05 01:08:18 UTC (rev 825) @@ -141,13 +141,13 @@ int alter_affixes(DIRFILE *dirfile, int index, gdpu_char *prefix, gdpu_char *suffix=NULL) int add_mplex(DIRFILE *dirfile, const char *field_code, const char *in_field, - const char *count_field, int count_val, int count_max, int fragment_index=0) + const char *count_field, int count_val, int period, int fragment_index=0) int alter_mplex(DIRFILE *dirfile, const char *field_code, gdpu_char *in_field=NULL, gdpu_char *count_field=NULL, int count_val=-1, - int count_max=-1) + int period=-1) int madd_mplex(DIRFILE *dirfile, const char *parent, const char *field_code, const char *in_field, const char *count_field, int count_val, - int count_max) + int period) int raw_close(DIRFILE *dirfile, const char *field_code) int desync(DIRFILE *dirfile, unsigned int flags=0) unsigned long int flags(DIRFILE *dirfile, unsigned long int set=0, Modified: trunk/getdata/bindings/perl/t/big_test.t =================================================================== --- trunk/getdata/bindings/perl/t/big_test.t 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/perl/t/big_test.t 2013-04-05 01:08:18 UTC (rev 825) @@ -1621,7 +1621,7 @@ CheckNum2(228, 2, $h{"fragment_index"}, 0); CheckNum2(228, 3, $h{"count_val"}, 1); CheckSArray2(228, 4, $h{"in_fields"}, 'data', 'sbit'); -CheckNum2(228, 5, $h{"count_max"}, 10); +CheckNum2(228, 5, $h{"period"}, 10); # 229: gd_add_mplex check $s = $_->add_mplex('new21', 'in1', 'in2', 5, 6, 0); @@ -1633,7 +1633,7 @@ CheckNum2(229, 2, $h{"fragment_index"}, 0); CheckNum2(229, 3, $h{"count_val"}, 5); CheckSArray2(229, 4, $h{"in_fields"}, 'in1', 'in2'); -CheckNum2(229, 5, $h{"count_max"}, 6); +CheckNum2(229, 5, $h{"period"}, 6); # 230: gd_madd_mplex check $s = $_->madd_mplex('data', 'mnew21', 'in2', 'in3', 0, 12); @@ -1645,7 +1645,7 @@ CheckNum2(230, 2, $h{"fragment_index"}, 0); CheckNum2(230, 3, $h{"count_val"}, 0); CheckSArray2(230, 4, $h{"in_fields"}, 'in2', 'in3'); -CheckNum2(230, 5, $h{"count_max"}, 12); +CheckNum2(230, 5, $h{"period"}, 12); # 231: gd_alter_mplex check $s = $_->alter_mplex('new21', 'in3', 'in4', -1, 7); @@ -1657,7 +1657,7 @@ CheckNum2(231, 2, $h{"fragment_index"}, 0); CheckNum2(231, 3, $h{"count_val"}, 5); CheckSArray2(231, 4, $h{"in_fields"}, 'in3', 'in4'); -CheckNum2(231, 5, $h{"count_max"}, 7); +CheckNum2(231, 5, $h{"period"}, 7); # 232: gd_strtok check @a = $_->strtok('"test1 test2" test3\ test4 test5'); Modified: trunk/getdata/bindings/python/pyentry.c =================================================================== --- trunk/getdata/bindings/python/pyentry.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/python/pyentry.c 2013-04-05 01:08:18 UTC (rev 825) @@ -480,7 +480,7 @@ &E->scalar[0], &E->EN(mplex,count_val)); gdpy_set_scalar_from_pyobj(PyTuple_GetItem(tuple, 3), GD_INT_TYPE, - &E->scalar[1], &E->EN(mplex,count_max)); + &E->scalar[1], &E->EN(mplex,period)); break; case GD_CARRAY_ENTRY: E->EN(scalar,array_len) = @@ -591,7 +591,7 @@ key[0] = "in_field1"; key[1] = "in_field2"; key[2] = "count_val"; - key[3] = "count_max"; + key[3] = "period"; size = 4; break; case GD_CARRAY_ENTRY: @@ -1713,7 +1713,7 @@ return 0; } -static PyObject *gdpy_entry_getcountmax(struct gdpy_entry_t *self, +static PyObject *gdpy_entry_getperiod(struct gdpy_entry_t *self, void *closure) { PyObject *obj = NULL; @@ -1722,42 +1722,42 @@ if (self->E->field_type == GD_MPLEX_ENTRY) { if (self->E->scalar[0] == NULL) - obj = PyInt_FromLong(self->E->EN(mplex,count_max)); + obj = PyInt_FromLong(self->E->EN(mplex,period)); else obj = PyString_FromString(self->E->scalar[0]); } else PyErr_Format(PyExc_AttributeError, "'pygetdata.entry' " - "attribute 'count_max' not available for entry type %s", + "attribute 'period' not available for entry type %s", gdpy_entry_type_names[self->E->field_type]); dreturn("%p", obj); return obj; } -static int gdpy_entry_setcountmax(struct gdpy_entry_t *self, PyObject *value, +static int gdpy_entry_setperiod(struct gdpy_entry_t *self, PyObject *value, void *closure) { - int count_max; + int period; char *scalar; dtrace("%p, %p, %p", self, value, closure); if (self->E->field_type != GD_MPLEX_ENTRY) { PyErr_Format(PyExc_AttributeError, "'pygetdata.entry' " - "attribute 'count_max' not available for entry type %s", + "attribute 'period' not available for entry type %s", gdpy_entry_type_names[self->E->field_type]); dreturn("%i", -1); return -1; } - gdpy_set_scalar_from_pyobj(value, GD_INT_TYPE, &scalar, &count_max); + gdpy_set_scalar_from_pyobj(value, GD_INT_TYPE, &scalar, &period); if (PyErr_Occurred()) { dreturn("%i", -1); return -1; } - self->E->EN(mplex,count_max) = count_max; + self->E->EN(mplex,period) = period; free(self->E->scalar[1]); self->E->scalar[1] = scalar; @@ -2032,7 +2032,7 @@ case GD_MPLEX_ENTRY: tuple = Py_BuildValue("(ssII)", self->E->in_fields[0], self->E->in_fields[1], (unsigned int)self->E->EN(mplex,count_val), - (unsigned int)self->E->EN(mplex,count_max)); + (unsigned int)self->E->EN(mplex,period)); break; } @@ -2229,14 +2229,8 @@ { "const_type", (getter)gdpy_entry_getdatatype, (setter)gdpy_entry_setdatatype, "An alias for the data_type attribute.", NULL }, - { "count_max", (getter)gdpy_entry_getcountmax, (setter)gdpy_entry_setcountmax, - "The maximum value of the counter of a MPLEX field. If this is\n" - "specified using a CONST scalar field, this will be the field code of\n" - "that field, otherwise, it will be the number itself.", - NULL }, { "count_val", (getter)gdpy_entry_getcountval, (setter)gdpy_entry_setcountval, "The target value of the counter of a MPLEX field. If this is\n" - /* ------ handy ruler ----------------------------------------------| */ "specified using a CONST scalar field, this will be the field code of\n" "that field, otherwise, it will be the number itself.", NULL }, @@ -2321,6 +2315,13 @@ "dictionary, in which case it will be converted internally to the\n" "corresponding parameters tuple.", NULL }, + { "period", (getter)gdpy_entry_getperiod, (setter)gdpy_entry_setperiod, + "The number of samples between successive occurrences of the MPLEX\n" + "value in the index vector (or zero, if unknown or not constant). If\n" + /* ------ handy ruler ----------------------------------------------| */ + "this is specified using a CONST scalar field, this will be the field\n" + "code of that field, otherwise, it will be the number itself.", + NULL }, { "poly_ord", (getter)gdpy_entry_getpolyord, (setter)gdpy_entry_setpolyord, "The polynomial order of a POLYNOM field. Modifying this will change\n" "the number of terms in the polynomial. If this number is increased,\n" Modified: trunk/getdata/bindings/python/test/big_test.py =================================================================== --- trunk/getdata/bindings/python/test/big_test.py 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/bindings/python/test/big_test.py 2013-04-05 01:08:18 UTC (rev 825) @@ -1850,7 +1850,7 @@ CheckSimple2(228, 2, ent.fragment, 0) CheckSimple2(228, 3, ent.count_val, 1) CheckSimple2(228, 4, ent.in_fields, ( 'data', 'sbit' )) -CheckSimple2(228, 5, ent.count_max, 10) +CheckSimple2(228, 5, ent.period, 10) # 229: gd_add_mplex check ent = pygetdata.entry(pygetdata.MPLEX_ENTRY, "new21", 0, ("in1", "in2", 5, 6)) @@ -1867,7 +1867,7 @@ CheckSimple2(229, 2, ent.fragment, 0) CheckSimple2(229, 3, ent.count_val, 5) CheckSimple2(229, 4, ent.in_fields, ( 'in1', 'in2' )) -CheckSimple2(229, 5, ent.count_max, 6) +CheckSimple2(229, 5, ent.period, 6) # 230: gd_madd_mplex check ent = pygetdata.entry(pygetdata.MPLEX_ENTRY, "mnew21", 0, ("in2", "in3", 0, 12)) @@ -1884,11 +1884,11 @@ CheckSimple2(230, 2, ent.fragment, 0) CheckSimple2(230, 3, ent.count_val, 0) CheckSimple2(230, 4, ent.in_fields, ( 'in2', 'in3' )) -CheckSimple2(230, 5, ent.count_max, 12) +CheckSimple2(230, 5, ent.period, 12) # 231: gd_alter_mplex check ent = pygetdata.entry(pygetdata.MPLEX_ENTRY, "new21", 0, { "count_val": 3, - "in_field1": "in3", "in_field2": "in4", "count_max": 7 }) + "in_field1": "in3", "in_field2": "in4", "period": 7 }) try: d.alter('new21', ent) except: @@ -1902,7 +1902,7 @@ CheckSimple2(231, 2, ent.fragment, 0) CheckSimple2(231, 3, ent.count_val, 3) CheckSimple2(231, 4, ent.in_fields, ( 'in3', 'in4' )) -CheckSimple2(231, 5, ent.count_max, 7) +CheckSimple2(231, 5, ent.period, 7) # 232: gd_strtok check try: Modified: trunk/getdata/man/dirfile-format.5 =================================================================== --- trunk/getdata/man/dirfile-format.5 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/dirfile-format.5 2013-04-05 01:08:18 UTC (rev 825) @@ -13,7 +13,7 @@ .\" Texts. A copy of the license is included in the `COPYING.DOC' file .\" as part of this distribution. .\" -.TH dirfile\-format 5 "12 July 2012" "Standards Version 9" "DATA FORMATS" +.TH dirfile\-format 5 "3 April 2013" "Standards Version 9" "DATA FORMATS" .SH NAME dirfile\-format \(em the dirfile database format specification file .SH DESCRIPTION @@ -808,7 +808,7 @@ .IP .I <fieldname> .B MPLEX -.I <input> <index> <count> \fR[\fI<max>\fR] +.I <input> <index> <count> \fR[\fI<period>\fR] .PP where .I input @@ -819,18 +819,22 @@ is the value of the multiplex index when the computed field is stored in .IR input , and -.I max -is the nominal maximum value which the multiplex index takes. If -.I max -is omitted, zero is assumed. If -.I max -is non-zero, the relation -.IR count " <= " max -must hold. Both +.IR period , +if present and non-zero, is the number of samples between successive occurrances +of the value .I count +in the index vector. A +.I period +of zero (or, equivalently, it's omission) indicates that either the value +.I count +is not equally spaced in the index vector, or else that the spacing is unknown. +Both +.I count and -.I max -are non-negative integers. +.I period +are integers, and +.I period +may not be negative. .PP At every sample .IR n , @@ -850,19 +854,19 @@ The values of .I count and -.I max +.I period place no restrictions on values contained in .IR index . Specifically, samples of .I index may exceed -.IR max . +.IR period . Particular values of .I index (including .IR count ) need not be equally spaced (neither by -.I max +.I period nor any other spacing); .I index need not ever take on the value Modified: trunk/getdata/man/gd_add_bit.3 =================================================================== --- trunk/getdata/man/gd_add_bit.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_add_bit.3 2013-04-05 01:08:18 UTC (rev 825) @@ -62,7 +62,7 @@ .HP .BI "int gd_add_mplex(DIRFILE *" dirfile ", const char *" field_name , .BI "const char *" in_field ", const char *" count_field , -.BI "int " count_val ", int " count_max ", int " fragment_index ); +.BI "int " count_val ", int " period ", int " fragment_index ); .HP .BI "int gd_add_multiply(DIRFILE *" dirfile ", const char *" field_name , .BI "const char *" in_field1 ", const char *" in_field2 , Modified: trunk/getdata/man/gd_alter_bit.3 =================================================================== --- trunk/getdata/man/gd_alter_bit.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_alter_bit.3 2013-04-05 01:08:18 UTC (rev 825) @@ -56,7 +56,7 @@ .HP .BI "int gd_alter_mplex(DIRFILE *" dirfile ", const char *" field_name , .BI "const char *" in_field ", const char *" count_field , -.BI "int " count_val ", int " count_max ); +.BI "int " count_val ", int " period ); .HP .BI "int gd_alter_multiply(DIRFILE *" dirfile ", const char *" field_code , .BI "const char *" in_field1 ", const char *" in_field2 ); @@ -170,7 +170,7 @@ .IR spf ", " n_fields ", " numbits ", " cdividend ", or " dividend ; .TP .B -1\fR: -.IR bitnum ", " count_val ", or " count_max ; +.IR bitnum " or " period ; .TP .B GD_NULL\fR: .IR data_type " or " const_type ; Modified: trunk/getdata/man/gd_cbopen.3 =================================================================== --- trunk/getdata/man/gd_cbopen.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_cbopen.3 2013-04-05 01:08:18 UTC (rev 825) @@ -1,6 +1,6 @@ .\" gd_cbopen.3. The gd_cbopen man page. .\" -.\" Copyright (C) 2008, 2009, 2010, 2011, 2012 D. V. Wiebe +.\" Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013 D. V. Wiebe .\" .\"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" .\" @@ -13,7 +13,7 @@ .\" Texts. A copy of the license is included in the `COPYING.DOC' file .\" as part of this distribution. .\" -.TH gd_cbopen 3 "1 April 2012" "Version 0.8.0" "GETDATA" +.TH gd_cbopen 3 "3 April 2013" "Version 0.8.4" "GETDATA" .SH NAME gd_cbopen, gd_open \(em open or create a dirfile .SH SYNOPSIS @@ -514,8 +514,7 @@ An attempt was made to add a RAW metafield. .TP .B GD_E_FORMAT_MPLEXVAL -A MPLEX specification has a negative count_max or count_val, or else had -a positive count_max, and count_val was larger than it. +A MPLEX specification has a negative period. .TP .B GD_E_FORMAT_N_FIELDS The number of fields of a LINCOM field was out-of-range. Modified: trunk/getdata/man/gd_entry.3 =================================================================== --- trunk/getdata/man/gd_entry.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_entry.3 2013-04-05 01:08:18 UTC (rev 825) @@ -1,6 +1,6 @@ .\" gd_entry.3. The gd_entry man page. .\" -.\" Copyright (C) 2008, 2009, 2010, 2011, 2012 D. V. Wiebe +.\" Copyright (C) 2008, 2009, 2010, 2011, 2012, 2013 D. V. Wiebe .\" .\"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" .\" @@ -13,7 +13,7 @@ .\" Texts. A copy of the license is included in the `COPYING.DOC' file .\" as part of this distribution. .\" -.TH gd_entry 3 "15 August 2012" "Version 0.8.1" "GETDATA" +.TH gd_entry 3 "3 April 2013" "Version 0.8.4" "GETDATA" .SH NAME gd_entry \(em retrieve a dirfile field's metadata .SH SYNOPSIS @@ -240,7 +240,7 @@ fields, the first element corresponds to .I count_val and the second to -.IR count_max . +.IR period . The remainder are uninitialised. .IP \(bu For @@ -545,7 +545,7 @@ const char *in_fields[2]; /* input field codes */ int count_val; /* value of the multiplex index */ - int count_max; /* maximum of the multiplex index */ + int period; /* samples between successive count_vals */ ... } gd_entry_t; @@ -564,10 +564,12 @@ in the input field. .PP The -.I count_max -member is the maximum value of the multiplex index, or zero, if this is not -specified. This is only used to determine how far to look back for a starting -value for the output field; see +.I period +member is the number of samples between successive occurrances of +.I count_val +in the index vector, or zero, if this is not known or constant. This is only +used to determine how far to look back for a starting value for the output +field; see .BR gd_mplex_lookback (3). .SS MULTIPLY and DIVIDE Members @@ -919,7 +921,7 @@ double|b[3]|double|u.lincom.b[3] const char*|table|const char*|u.linterp.table int|count_val|int|u.mplex.count_val -int|count_max|int|u.mplex.count_max +int|period|int|u.mplex.period gd_shift_t|shift|gd_shift_t|u.phase.shift int|poly_ord|int|u.polynom.poly_ord double complex|ca[3]|double|u.polynom.ca[3][2] @@ -930,8 +932,8 @@ double|dividend|double|u.recip.dividend gd_type_t|const_type|gd_type_t|u.scalar.const_type size_t|array_len|size_t|u.scalar.array_len -gd_windop_t|count_val|gd_windop_t|u.window.windop -gd_triplet_t|count_max|gd_triplet_t|u.window.threshold +gd_windop_t|windop|gd_windop_t|u.window.windop +gd_triplet_t|threshold|gd_triplet_t|u.window.threshold .TE .PP In the case of complex valued data in the C89 API, the first element of the Modified: trunk/getdata/man/gd_madd_bit.3 =================================================================== --- trunk/getdata/man/gd_madd_bit.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_madd_bit.3 2013-04-05 01:08:18 UTC (rev 825) @@ -65,7 +65,7 @@ .BI "int gd_madd_mplex(DIRFILE *" dirfile , .BI "const char *" parent ", const char *" field_name , .BI "const char *" in_field ", const char *" count_field , -.BI "int " count_val ", int " count_max ); +.BI "int " count_val ", int " period ); .HP .BI "int gd_madd_multiply(DIRFILE *" dirfile , .BI "const char *" parent ", const char *" field_name , Modified: trunk/getdata/man/gd_mplex_lookback.3 =================================================================== --- trunk/getdata/man/gd_mplex_lookback.3 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/man/gd_mplex_lookback.3 2013-04-05 01:08:18 UTC (rev 825) @@ -1,6 +1,6 @@ .\" gd_mplex_lookback.3. The gd_mplex_lookback man page. .\" -.\" Copyright (C) 2012 D. V. Wiebe +.\" Copyright (C) 2012, 2013 D. V. Wiebe .\" .\"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" .\" @@ -13,7 +13,7 @@ .\" Texts. A copy of the license is included in the `COPYING.DOC' file .\" as part of this distribution. .\" -.TH gd_mplex_lookback 3 "20 June 2012" "Version 0.8.0" "GETDATA" +.TH gd_mplex_lookback 3 "3 April 2013" "Version 0.8.4" "GETDATA" .SH NAME gd_mplex_lookback \(em set the GetData lookback length for MPLEX fields. .SH SYNOPSIS @@ -61,30 +61,33 @@ Otherwise, .I lookback should be a positive number specifying the number of -.I MPLEX cycles -to search. Each .B MPLEX -field has its own MPLEX cycle length, measured in samples of the index field, -which is defined as follows: +periods to search. Each +.B MPLEX +field has its own period, measured in samples of the index field, which is +defined as follows: .IP \(bu if the .B MPLEX field in question specifies an optional -.I count_max -positive parameter (see the MPLEX definition in dirfile-format(5)), its MPLEX -cycle length is that many samples; +.I period +positive parameter (see the +.B MPLEX +definition in +.BR dirfile-format (5)), +its period is that many samples; .IP \(bu otherwise, if the .B MPLEX field's .I count_val -is at least five, its MPLEX cycle length is twice as many samples as that value; +is at least five, its period is one more sample than twice that value; .IP \(bu -otherwise, the +otherwise, the period is ten samples. +.PP +So, given the following .B MPLEX -cycle length is ten samples. -.PP -So, given the following MPLEX definitions: +definitions: .IP field1 \fBMPLEX\fR data_field index_field 7 12 .br @@ -95,22 +98,23 @@ field4 \fBMPLEX\fR data_field index_field 2 .PP .I field1 -has a cycle length of 12 samples and +has a period of 12 samples and .I field2 -a cycle length of 6 samples (both the value of their -.I count_max +a period of 6 samples (both the value of their +.I period parameters); .I field3 -has a cycle length of 14 samples (twice it's +has a period of 15 samples (one more than twice it's .IR count_val ), and .I field4 -has a cycle length of 10 samples (the default value, since its +has a period of 10 samples (the default value, since its .I count_val is less than five). .PP -The initial value of the MPLEX lookback is ten cycles. This value is provided -in getdata.h as +The initial value of the +.B MPLEX +lookback is ten periods. This value is provided in getdata.h as .BR GD_DEFAULT_LOOKBACK . This function always succeeds and returns no value. Modified: trunk/getdata/src/add.c =================================================================== --- trunk/getdata/src/add.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/add.c 2013-04-05 01:08:18 UTC (rev 825) @@ -428,7 +428,7 @@ break; case GD_MPLEX_ENTRY: E->EN(mplex,count_val) = entry->EN(mplex,count_val); - E->EN(mplex,count_max) = entry->EN(mplex,count_max); + E->EN(mplex,period) = entry->EN(mplex,period); if (_GD_CheckCodeAffixes(D, NULL, entry->in_fields[0], entry->fragment_index) || _GD_CheckCodeAffixes(D, NULL, @@ -441,15 +441,13 @@ E->in_fields[1] = _GD_Strdup(D, entry->in_fields[1]); E->e->u.mplex.type = GD_NULL; - if (entry->EN(mplex,count_max) < 0) - _GD_SetError(D, GD_E_BAD_ENTRY, GD_E_ENTRY_CNTMAX, NULL, - entry->EN(mplex,count_max), NULL); - else if (entry->EN(mplex,count_max) > 0 && - entry->EN(mplex,count_val) >= entry->EN(mplex,count_max)) - { + if (entry->EN(mplex,period) < 0) + _GD_SetError(D, GD_E_BAD_ENTRY, GD_E_ENTRY_PERIOD, NULL, + entry->EN(mplex,period), NULL); + else if (entry->EN(mplex,count_val) < 0) _GD_SetError(D, GD_E_BAD_ENTRY, GD_E_ENTRY_CNTVAL, NULL, entry->EN(mplex,count_val), NULL); - } + copy_scalar[0] = copy_scalar[1] = 1; break; case GD_CONST_ENTRY: @@ -1274,14 +1272,14 @@ /* add a MPLEX entry */ int gd_add_mplex(DIRFILE *D, const char *field_code, const char *in_field, - const char *count_field, int count_val, int count_max, int fragment_index) + const char *count_field, int count_val, int period, int fragment_index) gd_nothrow { gd_entry_t E; int error; dtrace("%p, \"%s\", \"%s\", \"%s\", %i, %i, %i", D, field_code, in_field, - count_field, count_val, count_max, fragment_index); + count_field, count_val, period, fragment_index); if (D->flags & GD_INVALID) {/* don't crash */ _GD_SetError(D, GD_E_BAD_DIRFILE, 0, NULL, 0, NULL); @@ -1293,7 +1291,7 @@ E.field = (char *)field_code; E.field_type = GD_MPLEX_ENTRY; E.EN(mplex,count_val) = count_val; - E.EN(mplex,count_max) = count_max; + E.EN(mplex,period) = period; E.in_fields[0] = (char *)in_field; E.in_fields[1] = (char *)count_field; E.fragment_index = fragment_index; @@ -1871,14 +1869,14 @@ /* add a META MPLEX entry */ int gd_madd_mplex(DIRFILE *D, const char *parent, const char *field_code, - const char *in_field, const char *count_field, int count_val, int count_max) + const char *in_field, const char *count_field, int count_val, int period) gd_nothrow { int error; gd_entry_t E; dtrace("%p, \"%s\", \"%s\", \"%s\", \"%s\", %i, %i", D, parent, field_code, - in_field, count_field, count_val, count_max); + in_field, count_field, count_val, period); if (D->flags & GD_INVALID) {/* don't crash */ _GD_SetError(D, GD_E_BAD_DIRFILE, 0, NULL, 0, NULL); @@ -1890,7 +1888,7 @@ E.field = (char *)field_code; E.field_type = GD_MPLEX_ENTRY; E.EN(mplex,count_val) = count_val; - E.EN(mplex,count_max) = count_max; + E.EN(mplex,period) = period; E.in_fields[0] = (char *)in_field; E.in_fields[1] = (char *)count_field; error = (_GD_Add(D, &E, parent) == NULL) ? -1 : 0; Modified: trunk/getdata/src/del.c =================================================================== --- trunk/getdata/src/del.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/del.c 2013-04-05 01:08:18 UTC (rev 825) @@ -204,7 +204,7 @@ _GD_DeReferenceOne(D, E, C, check, 0, GD_INT_TYPE, &E->EN(mplex,count_val)); _GD_DeReferenceOne(D, E, C, check, 1, GD_INT_TYPE, - &E->EN(mplex,count_max)); + &E->EN(mplex,period)); break; case GD_NO_ENTRY: case GD_LINTERP_ENTRY: Modified: trunk/getdata/src/entry.c =================================================================== --- trunk/getdata/src/entry.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/entry.c 2013-04-05 01:08:18 UTC (rev 825) @@ -274,7 +274,7 @@ break; case GD_MPLEX_ENTRY: _GD_GetScalar(D, E, 0, GD_INT_TYPE, &E->EN(mplex,count_val), err); - _GD_GetScalar(D, E, 1, GD_INT_TYPE, &E->EN(mplex,count_max), err); + _GD_GetScalar(D, E, 1, GD_INT_TYPE, &E->EN(mplex,period), err); break; case GD_NO_ENTRY: case GD_LINTERP_ENTRY: Modified: trunk/getdata/src/errors.c =================================================================== --- trunk/getdata/src/errors.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/errors.c 2013-04-05 01:08:18 UTC (rev 825) @@ -78,7 +78,7 @@ { GD_E_FORMAT, GD_E_FORMAT_ALIAS, "Cannot use alias {4} as parent to a meta field on line {3} of {2}", 0 }, { GD_E_FORMAT, GD_E_FORMAT_MPLEXVAL, - "Count value ({4}) exceeds maximum on line {3} of {2}", 0 }, + "Bad MPLEX period ({4}) on line {3} of {2}", 0 }, /* GD_E_TRUNC: 1 = suberror, 2 = filename. 3 = errno */ { GD_E_TRUNC, 0, "Error truncating {2}: ", 1 }, /* GD_E_CREAT: 1 = suberror, 2 = filename, 3 = errno */ @@ -139,7 +139,7 @@ { GD_E_BAD_ENTRY, GD_E_ENTRY_POLYORD, "POLYNOM order out of range: {3}", 0 }, { GD_E_BAD_ENTRY, GD_E_ENTRY_WINDOP, "Unrecognised WINDOW operator: {3}", 0 }, { GD_E_BAD_ENTRY, GD_E_ENTRY_CNTVAL, "Count value out of range: {3}", 0 }, - { GD_E_BAD_ENTRY, GD_E_ENTRY_CNTMAX, "Count max out of range: {3}", 0 }, + { GD_E_BAD_ENTRY, GD_E_ENTRY_PERIOD, "MPLEX period out of range: {3}", 0 }, /* GD_E_DUPLICATE: 4 = name */ { GD_E_DUPLICATE, 0, "Field code already present: {4}", 0 }, /* GD_E_DIMENSION: 2 = parent field (if any), 4 = field code */ Modified: trunk/getdata/src/flush.c =================================================================== --- trunk/getdata/src/flush.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/flush.c 2013-04-05 01:08:18 UTC (rev 825) @@ -534,10 +534,10 @@ fputc(' ', stream); _GD_WriteConst(D, stream, me, permissive, GD_INT_TYPE, &E->EN(mplex,count_val), E->scalar[0], E->scalar_ind[0], ""); - if (E->EN(mplex,count_max) > 0 || E->scalar[1]) { + if (E->EN(mplex,period) > 0 || E->scalar[1]) { fputc(' ', stream); _GD_WriteConst(D, stream, me, permissive, GD_INT_TYPE, - &E->EN(mplex,count_max), E->scalar[1], E->scalar_ind[1], "\n"); + &E->EN(mplex,period), E->scalar[1], E->scalar_ind[1], "\n"); } else fputc('\n', stream); break; Modified: trunk/getdata/src/getdata.c =================================================================== --- trunk/getdata/src/getdata.c 2013-03-19 20:22:16 UTC (rev 824) +++ trunk/getdata/src/getdata.c 2013-04-05 01:08:18 UTC (rev 825) @@ -1696,15 +1696,14 @@ else if (tmpbuf[0] != E->EN(mplex,count_val) && D->lookback) { /* It wasn't -- do a look-back to find the start value. On a, say, gzipped * field this is expensive sin... [truncated message content] |
From: <ket...@us...> - 2013-03-19 20:22:19
|
Revision: 824 http://sourceforge.net/p/getdata/code/824 Author: ketiltrout Date: 2013-03-19 20:22:16 +0000 (Tue, 19 Mar 2013) Log Message: ----------- Fix year for 2013. Modified Paths: -------------- trunk/getdata/ChangeLog Modified: trunk/getdata/ChangeLog =================================================================== --- trunk/getdata/ChangeLog 2013-03-16 01:37:28 UTC (rev 823) +++ trunk/getdata/ChangeLog 2013-03-19 20:22:16 UTC (rev 824) @@ -1,9 +1,9 @@ -2012-03-13 D. V. Wiebe <ge...@ke...> svn:819 +2013-03-13 D. V. Wiebe <ge...@ke...> svn:819 * src/flush.c (_GD_FlushFragment): Strip affixes from field codes in /REFERENCE directives. * test/flush_ref.c test/parse_include_affix_ref.c: Added. -2012-03-12 D. V. Wiebe <ge...@ke...> svn:818 +2013-03-12 D. V. Wiebe <ge...@ke...> svn:818 * bindings/python/pydirfile.c (gdpy_dirfile_getdata): Resize the ndarray before returning it, if necessary. Also, don't try to read past the EOF in read-to-end mode. @@ -19,16 +19,16 @@ * src/gzip.c (_GD_GzipSeek): Allow seeking to sample zero. * test/gzip_get_get2.c: Added. -2012-03-12 D. V. Wiebe <ge...@ke...> svn:815 +2013-03-12 D. V. Wiebe <ge...@ke...> svn:815 GetData-0.8.3 released. -2012-03-09 D. V. Wiebe <ge...@ke...> svn:807 +2013-03-09 D. V. Wiebe <ge...@ke...> svn:807 * src/flush.c: C89-ify the GD_VERS_... constants. -2012-03-08 D. V. Wiebe <ge...@ke...> svn:806 +2013-03-08 D. V. Wiebe <ge...@ke...> svn:806 GetData-0.8.3rc1. -2012-03-08 D. V. Wiebe <ge...@ke...> svn:803 +2013-03-08 D. V. Wiebe <ge...@ke...> svn:803 * src/internal.h (gd_put_unalinged64): Fix spelling. * src/encoding.c (_GD_FiniRawIO): Don't pass NULL to gd_UnlinkAt. @@ -39,7 +39,7 @@ Valeev. Also add add --enable-fast-unaligned to allow users to override the check. -2012-02-15 D. V. Wiebe <ge...@ke...> svn:795 +2013-02-15 D. V. Wiebe <ge...@ke...> svn:795 * bindings/matlab/package: Added. * Makefile.am: Add matlabdist and matlabdistcheck @@ -53,16 +53,16 @@ * bindings/matlab/gd_include.c: Renamed from gd_include_affix.c * bindings/matlab/gd_include.m: Deleted. -2012-02-13 D. V. Wiebe <ge...@ke...> svn:794 +2013-02-13 D. V. Wiebe <ge...@ke...> svn:794 * bindings/cxx/test/big_test.cpp bindings/perl/t/big_test.t bindings/python/test/big_test.py: Add test 243. -2012-02-06 D. V. Wiebe <ge...@ke...> svn:793 +2013-02-06 D. V. Wiebe <ge...@ke...> svn:793 * src/parse.c (_GD_Tokenise): Don't falsely report an unterminated token when stopping a partial tokenisation on top of a " or \. * test/tok_arg.c test/tok_escape.c test/tok_quote.c: Added. -2012-02-02 D. V. Wiebe <ge...@ke...> svn:792 +2013-02-02 D. V. Wiebe <ge...@ke...> svn:792 * src/string.c (gd_get_string): Handle string retrieval directly instead of calling _GD_DoField. * src/string.c (_GD_DoStringOut): Moved from putdata.c. @@ -72,10 +72,10 @@ * src/getdata.c (_GD_DoField) src/putdata.c (_GD_DoFieldOut): Remove string processing. -2012-02-02 D. V. Wiebe <ge...@ke...> svn:790 +2013-02-02 D. V. Wiebe <ge...@ke...> svn:790 * bindings/matlab/matlab.c: ANSI C. -2012-02-02 D. V. Wiebe <ge...@ke...> svn:789 +2013-02-02 D. V. Wiebe <ge...@ke...> svn:789 * bindings/python/pyentry.c (gdpy_set_scalar_from_pyobj): Add missing data types. * bindings/python/pyentry.c (gdpy_set_entry_from_tuple gdpy_entry_setspf @@ -91,7 +91,7 @@ * bindings/python/test/big_test.py: Fix the part of test 35 that the previous fix broke. -2012-02-02 D. V. Wiebe <ge...@ke...> svn:788 +2013-02-02 D. V. Wiebe <ge...@ke...> svn:788 * src/debug.c (gd_colclear): Added. * src/protect.c (gd_protection gd_alter_protection): Fix error reporting for @@ -103,12 +103,12 @@ * bindings/python/test/big_test.py: Fixed tests 35 and 67. -2012-01-26 D. V. Wiebe <ge...@ke...> svn:787 +2013-01-26 D. V. Wiebe <ge...@ke...> svn:787 * src/del.c (_GD_DeReference) src/entry.c (_GD_CalculateEntry) src/flush.c (_GD_FieldSpec) src/mod.c (_GD_Change): Fix data type (size) of EN(raw,spf) in function calls. -2012-01-15 D. V. Wiebe <ge...@ke...> svn:785 +2013-01-15 D. V. Wiebe <ge...@ke...> svn:785 * m4/floatordering.m4: Split from m4/compiler.m4 * src/parse.c (_GD_ParseRaw _GD_ParseMplex): Fix types in _GD_SetScalar This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-03-16 01:37:32
|
Revision: 823 http://sourceforge.net/p/getdata/code/823 Author: ketiltrout Date: 2013-03-16 01:37:28 +0000 (Sat, 16 Mar 2013) Log Message: ----------- Doc updates. Modified Paths: -------------- trunk/defile/bin/defile.c trunk/defile/doc/defile.1.in Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-03-16 01:16:36 UTC (rev 822) +++ trunk/defile/bin/defile.c 2013-03-16 01:37:28 UTC (rev 823) @@ -2481,7 +2481,7 @@ NULL, "turn on asynchronous mode" }, { DF_WOPT_SYNC, DF_OPT_PLUS | DF_OPT_NO_ARG, 'a', "sync", "Synchronous", - NULL, "turn off synchronous mode" + NULL, "turn off asynchronous mode (default)" }, { DF_WOPT_CLOBBER, DF_OPT_NO_ARG, 0, "clobber", "Clobber", NULL, "if the output dirfile already exists, overwrite it; use with caution" Modified: trunk/defile/doc/defile.1.in =================================================================== --- trunk/defile/doc/defile.1.in 2013-03-16 01:16:36 UTC (rev 822) +++ trunk/defile/doc/defile.1.in 2013-03-16 01:37:28 UTC (rev 823) @@ -208,20 +208,21 @@ don't overwrite an existing dirfile. This is the default behaviour. (Directive: .BR NoClobber ) .TP -.BR \-D ", " \-\-directory=\fIDIR +.BR \-D ", " \-\-directory=\fIPATH unless .B \-\-output is given and specifies an absolute path, write the output dirfile as a subdirectory under -.IR DIR . +.IR PATH . If .B \-\-output is not specified, then name of the output dirfile created under -.B DIR +.B PATH will be provided by the input plugin, or else be based on .IR INPUT . If -.B \-\-output does specify an absolute path, this option is ignored. (Directive: +.B \-\-output +does specify an absolute path, this option is ignored. (Directive: .BR Directory ) .TP .BR \-o ", " \-\-output=\fIPATH @@ -236,22 +237,10 @@ directories specified in .IR PATH . Using this option may have averse effects if the input causes defile to cycle as -explained above. -.IP -Some input plugins may trigger defile to create more than one consecutive output -dirfile (in cases when the input plugin notices a change in the data source -metadata or name). When this occurs while using this option, if -.B \-\-clobber -has been specified, defile will truncate the old dirfile that it was just -writing, and overwrite it with a new (empty) one at -.IR PATH . -If -.B \-\-clobber -has not been specified, defile will exit with an error, having been asked to -overwrite an existing dirfile. (Directive: +explained above. (Directive: .BR Output ) .TP -.BR \-\-cut\-dirs= N +.BI \-\-cut\-dirs= N When no output dirfile name is explicitly given, defile will generate one from the .I INPUT @@ -271,6 +260,40 @@ .B \-\-output is used to explicitly name the output dirfile. (Directive: .BR CutDirs ) +.TP +.BR \-S ", " \-\-symlink=\fIPATH +Create a symlink called +.I PATH +(relative to the current directory, if not absolute) pointing to the output +dirfile. An existing file or symlink called +.I PATH +will be overwritten. The symlink is updated if the input plugin causes defile +to cycle between output dirfiles. The traditional name of the symlink is +.IR defile.lnk . +(Directive: +.BR Symlink ) +.TP +.BR +S ", " \-\-no\-symlink +Don't create a symlink. This is the default behaviour. (Directive: +.BR NoSymlink ) +.TP +.BR \-C ", " \-\-curfile=\fIPATH +Create a text file called +.I PATH +(relative to the current directory, if not absolute) containing the full +pathname of the output dirfile. An existing file called +.I PATH +will be overwritten. The file is updated (re-written) if the input plugin +causes defile to cycle between output dirfiles. In the Dirfile milieu, this +is known as a "curfile", and can be used as a poor man's symlink. The +traditional name of the file is +.IR defile.cur . +(Directive: +.BR CurFile ) +.TP +.BR +C ", " \-\-no\-curfile +Don't create a curfile. This is the default behaviour. (Directive: +.BR NoCurFile ) .SS Running Mode Options The following options affect the modes in which defile runs. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ket...@us...> - 2013-03-16 01:16:38
|
Revision: 822 http://sourceforge.net/p/getdata/code/822 Author: ketiltrout Date: 2013-03-16 01:16:36 +0000 (Sat, 16 Mar 2013) Log Message: ----------- --clobber-once Modified Paths: -------------- trunk/defile/bin/defile.c trunk/defile/doc/defile.1.in trunk/defile/lib/libdefile.c Modified: trunk/defile/bin/defile.c =================================================================== --- trunk/defile/bin/defile.c 2013-03-15 02:09:51 UTC (rev 821) +++ trunk/defile/bin/defile.c 2013-03-16 01:16:36 UTC (rev 822) @@ -943,7 +943,7 @@ DF_WOPT_VERBOSE, DF_WOPT_REMOTE, DF_WOPT_LOCAL, DF_WOPT_RSH, DF_WOPT_LISTEN, DF_WOPT_NOLISTEN, DF_WOPT_RCMD, DF_WOPT_RDEBUG, DF_WOPT_NORDEBUG, DF_WOPT_SRVRATE, DF_WOPT_DAEMON, DF_WOPT_CURFILE, DF_WOPT_SYMLINK, - DF_WOPT_NOSYMLINK, DF_WOPT_NOCURFILE + DF_WOPT_NOSYMLINK, DF_WOPT_NOCURFILE, DF_WOPT_CLOBBERONE }; static int DF_OutputOpt(struct df_defile *df, struct df_rc_config *config, @@ -1060,8 +1060,10 @@ SETULONG(BLEN, buflen); SETLINT(CLOBBER, clobber, 1); + SETLINT(CLOBBERONE, clobber, 2); SETLINT(NOCLOBBER, clobber, 0); + SETINT(CUTDIR, cutdir); SETMODE(NODAEMON, DF_MODE_NO_DAEMON); @@ -2484,6 +2486,9 @@ { DF_WOPT_CLOBBER, DF_OPT_NO_ARG, 0, "clobber", "Clobber", NULL, "if the output dirfile already exists, overwrite it; use with caution" }, + { DF_WOPT_CLOBBERONE, DF_OPT_NO_ARG, 0, "clobber-once", "ClobberOnce", NULL, + "like --clobber, but only overwrite the first output dirfile" + }, { DF_WOPT_NOCLOBBER, DF_OPT_NO_ARG, 0, "no-clobber", "NoClobber", NULL, "don't overwrite an existing dirfile (default)" }, @@ -2772,7 +2777,7 @@ df_subset_reset(df->ofl, DF_SUBSET_INIT); } if (df->clobber) { - df_dprintf(DF_PRN_WARN, "ignoring --clobber specified " + df_dprintf(DF_PRN_WARN, "ignoring --clobber or --clobber-once specified " "with --listen\n"); } if (df->srv_rate < 1e-5) { Modified: trunk/defile/doc/defile.1.in =================================================================== --- trunk/defile/doc/defile.1.in 2013-03-15 02:09:51 UTC (rev 821) +++ trunk/defile/doc/defile.1.in 2013-03-16 01:16:36 UTC (rev 822) @@ -172,15 +172,18 @@ .B \-\-output has been specified, the new dirfile will have the same name as the old one. If .B \-\-clobber -has been given, the old dirfile will be overwitten. If +has been given, defile will delete the dirfile it just finished. If .B \-\-clobber -has not been specified, defile will exit with an error, just as if it had been -asked to overwrite an existing dirfile. If +has not been given, defile will exit with an error, just as if it had been asked +to overwrite an existing dirfile. If .B \-\-output has not been specified, and the input plugin provides a new name, a new output dirfile will be created in the directory specified with .BR \-\-directory , -if possible. +if possible. If you want to clobber a pre-existing, explicitly named output +dirfile, but not allow the input plugin to cause defile to overwrite its output, +use +.BR \-\-clobber\-once . .TP .B \-\-clobber @@ -189,6 +192,18 @@ caution! (Directive: .BR Clobber ) .TP +.B \-\-clobber\-once +like +.BR \-\-clobber , +but only allow overwriting an existing dirfile the +.I first +time defile creates a dirfile. The distinction is only meaningful if the input +plugin tries to create multiple dirfiles in succession, and is typically only +useful when also specifying an output dirfile name (via +.BR \-\-output ). +See the discussion above. (Directive: +.BR ClobberOnce ) +.TP .B \-\-no\-clobber don't overwrite an existing dirfile. This is the default behaviour. (Directive: .BR NoClobber ) Modified: trunk/defile/lib/libdefile.c =================================================================== --- trunk/defile/lib/libdefile.c 2013-03-15 02:09:51 UTC (rev 821) +++ trunk/defile/lib/libdefile.c 2013-03-16 01:16:36 UTC (rev 822) @@ -1463,9 +1463,11 @@ pthread_mutex_lock(&df_config_mx); df->input_offset = df->offset = 0; df->mode_flags &= ~DF_MODE_APPEND; + if (df->clobber > 1) /* --clobber-once */ + df->clobber = 0; pthread_mutex_unlock(&df_config_mx); - /* trigger and wait for completion of the output -- in server mode, this + /* trigger and wait for completion of the output -- in server mode, * the output will send a special RPC to the clients indicating reinit */ DF_INSTATE_MX(BUILD); if (mode == DF_REINIT_DROP) { @@ -1482,7 +1484,6 @@ * input to abort now. */ if (df->output_state != DF_ST_BUILD) { DF_INSTATE_MX(ABORT); - pthread_mutex_unlock(&df_state_mx); return df_input_abort(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |