Unverified Commit 2ddba97d authored by Graham, Aaron's avatar Graham, Aaron Committed by GitHub
Browse files

7 d ints and reals (#311)

* Add's 5D, 6D, and 7D support for SSK, SLK, SNK, and SDK parameters

* Add support for higher order int/real arrays when reading/writing HDF5 parameter lists
parent 9be652ee
......@@ -3766,6 +3766,22 @@ SUBROUTINE write_pList(thisHDF5File,dsetname,vals,gdims_in,first_dir)
INTEGER(SLK),ALLOCATABLE :: id3(:,:,:)
REAL(SSK),ALLOCATABLE :: rs3(:,:,:)
REAL(SDK),ALLOCATABLE :: rd3(:,:,:)
INTEGER(SNK),ALLOCATABLE :: is4(:,:,:,:)
INTEGER(SLK),ALLOCATABLE :: id4(:,:,:,:)
REAL(SSK),ALLOCATABLE :: rs4(:,:,:,:)
REAL(SDK),ALLOCATABLE :: rd4(:,:,:,:)
INTEGER(SNK),ALLOCATABLE :: is5(:,:,:,:,:)
INTEGER(SLK),ALLOCATABLE :: id5(:,:,:,:,:)
REAL(SSK),ALLOCATABLE :: rs5(:,:,:,:,:)
REAL(SDK),ALLOCATABLE :: rd5(:,:,:,:,:)
INTEGER(SNK),ALLOCATABLE :: is6(:,:,:,:,:,:)
INTEGER(SLK),ALLOCATABLE :: id6(:,:,:,:,:,:)
REAL(SSK),ALLOCATABLE :: rs6(:,:,:,:,:,:)
REAL(SDK),ALLOCATABLE :: rd6(:,:,:,:,:,:)
INTEGER(SNK),ALLOCATABLE :: is7(:,:,:,:,:,:,:)
INTEGER(SLK),ALLOCATABLE :: id7(:,:,:,:,:,:,:)
REAL(SSK),ALLOCATABLE :: rs7(:,:,:,:,:,:,:)
REAL(SDK),ALLOCATABLE :: rd7(:,:,:,:,:,:,:)
INTEGER(SIK) :: i
......@@ -3857,6 +3873,54 @@ SUBROUTINE write_pList(thisHDF5File,dsetname,vals,gdims_in,first_dir)
CASE('3-D ARRAY INTEGER(SLK)')
CALL vals%get(CHAR(address),id3)
CALL thisHDF5File%write_l3(CHAR(path),id3)
CASE('4-D ARRAY REAL(SSK)')
CALL vals%get(CHAR(address),rs4)
CALL thisHDF5File%write_s4(CHAR(path),rs4)
CASE('4-D ARRAY REAL(SDK)')
CALL vals%get(CHAR(address),rd4)
CALL thisHDF5File%write_d4(CHAR(path),rd4)
CASE('4-D ARRAY INTEGER(SNK)')
CALL vals%get(CHAR(address),is4)
CALL thisHDF5File%write_n4(CHAR(path),is4)
CASE('4-D ARRAY INTEGER(SLK)')
CALL vals%get(CHAR(address),id4)
CALL thisHDF5File%write_l4(CHAR(path),id4)
CASE('5-D ARRAY REAL(SSK)')
CALL vals%get(CHAR(address),rs5)
CALL thisHDF5File%write_s5(CHAR(path),rs5)
CASE('5-D ARRAY REAL(SDK)')
CALL vals%get(CHAR(address),rd5)
CALL thisHDF5File%write_d5(CHAR(path),rd5)
CASE('5-D ARRAY INTEGER(SNK)')
CALL vals%get(CHAR(address),is5)
CALL thisHDF5File%write_n5(CHAR(path),is5)
CASE('5-D ARRAY INTEGER(SLK)')
CALL vals%get(CHAR(address),id5)
CALL thisHDF5File%write_l5(CHAR(path),id5)
CASE('6-D ARRAY REAL(SSK)')
CALL vals%get(CHAR(address),rs6)
CALL thisHDF5File%write_s6(CHAR(path),rs6)
CASE('6-D ARRAY REAL(SDK)')
CALL vals%get(CHAR(address),rd6)
CALL thisHDF5File%write_d6(CHAR(path),rd6)
CASE('6-D ARRAY INTEGER(SNK)')
CALL vals%get(CHAR(address),is6)
CALL thisHDF5File%write_n6(CHAR(path),is6)
CASE('6-D ARRAY INTEGER(SLK)')
CALL vals%get(CHAR(address),id6)
CALL thisHDF5File%write_l6(CHAR(path),id6)
CASE('7-D ARRAY REAL(SSK)')
CALL vals%get(CHAR(address),rs7)
CALL thisHDF5File%write_s7(CHAR(path),rs7)
CASE('7-D ARRAY REAL(SDK)')
CALL vals%get(CHAR(address),rd7)
CALL thisHDF5File%write_d7(CHAR(path),rd7)
CASE('7-D ARRAY INTEGER(SNK)')
CALL vals%get(CHAR(address),is7)
CALL thisHDF5File%write_n7(CHAR(path),is7)
CASE('7-D ARRAY INTEGER(SLK)')
CALL vals%get(CHAR(address),id7)
CALL thisHDF5File%write_l7(CHAR(path),id7)
CASE DEFAULT
CALL thisHDF5File%e%raiseError(modName//'::'//myName// &
' - Unrecognized Parameter Type '//CHAR(nextParam%dataType)//'.')
......@@ -6187,12 +6251,16 @@ SUBROUTINE read_parameter(thisHDF5File,h5path,vals)
LOGICAL(SBK),ALLOCATABLE :: l1(:),l2(:,:),l3(:,:,:)
INTEGER(SNK) :: is0
INTEGER(SNK),ALLOCATABLE :: is1(:),is2(:,:),is3(:,:,:),is4(:,:,:,:)
INTEGER(SNK),ALLOCATABLE :: is5(:,:,:,:,:),is6(:,:,:,:,:,:),is7(:,:,:,:,:,:,:)
INTEGER(SLK) :: id0
INTEGER(SLK),ALLOCATABLE :: id1(:),id2(:,:),id3(:,:,:),id4(:,:,:,:)
INTEGER(SLK),ALLOCATABLE :: id5(:,:,:,:,:),id6(:,:,:,:,:,:),id7(:,:,:,:,:,:,:)
REAL(SSK) :: rs0
REAL(SSK),ALLOCATABLE :: rs1(:),rs2(:,:),rs3(:,:,:),rs4(:,:,:,:)
REAL(SSK),ALLOCATABLE :: rs5(:,:,:,:,:),rs6(:,:,:,:,:,:),rs7(:,:,:,:,:,:,:)
REAL(SDK) :: rd0
REAL(SDK),ALLOCATABLE :: rd1(:),rd2(:,:),rd3(:,:,:),rd4(:,:,:,:)
REAL(SDK),ALLOCATABLE :: rd5(:,:,:,:,:),rd6(:,:,:,:,:,:),rd7(:,:,:,:,:,:,:)
TYPE(StringType) :: st0
TYPE(StringType),ALLOCATABLE :: st1(:),st2(:,:),st3(:,:,:)
......@@ -6233,6 +6301,15 @@ SUBROUTINE read_parameter(thisHDF5File,h5path,vals)
CASE(4)
CALL read_l4(thisHDF5File,CHAR(plpath),id4)
CALL vals%add(CHAR(plpath),id4)
CASE(5)
CALL read_l5(thisHDF5File,CHAR(plpath),id5)
CALL vals%add(CHAR(plpath),id5)
CASE(6)
CALL read_l6(thisHDF5File,CHAR(plpath),id6)
CALL vals%add(CHAR(plpath),id6)
CASE(7)
CALL read_l7(thisHDF5File,CHAR(plpath),id7)
CALL vals%add(CHAR(plpath),id7)
CASE DEFAULT
CALL thisHDF5File%e%raiseWarning(modName//'::'//myName// &
' - Unsupported INTEGER(SLK) dimension '//str(ndims)//'!')
......@@ -6256,6 +6333,15 @@ SUBROUTINE read_parameter(thisHDF5File,h5path,vals)
CASE(4)
CALL read_n4(thisHDF5File,CHAR(plpath),is4)
CALL vals%add(CHAR(plpath),is4)
CASE(5)
CALL read_n5(thisHDF5File,CHAR(plpath),is5)
CALL vals%add(CHAR(plpath),is5)
CASE(6)
CALL read_n6(thisHDF5File,CHAR(plpath),is6)
CALL vals%add(CHAR(plpath),is6)
CASE(7)
CALL read_n7(thisHDF5File,CHAR(plpath),is7)
CALL vals%add(CHAR(plpath),is7)
CASE DEFAULT
CALL thisHDF5File%e%raiseWarning(modName//'::'//myName// &
' - Unsupported INTEGER(SNK) dimension '//str(ndims)//'!')
......@@ -6282,6 +6368,15 @@ SUBROUTINE read_parameter(thisHDF5File,h5path,vals)
CASE(4)
CALL read_d4(thisHDF5File,CHAR(plpath),rd4)
CALL vals%add(CHAR(plpath),rd4)
CASE(5)
CALL read_d5(thisHDF5File,CHAR(plpath),rd5)
CALL vals%add(CHAR(plpath),rd5)
CASE(6)
CALL read_d6(thisHDF5File,CHAR(plpath),rd6)
CALL vals%add(CHAR(plpath),rd6)
CASE(7)
CALL read_d7(thisHDF5File,CHAR(plpath),rd7)
CALL vals%add(CHAR(plpath),rd7)
CASE DEFAULT
CALL thisHDF5File%e%raiseWarning(modName//'::'//myName// &
' - Unsupported REAL(SDK) dimension '//str(ndims)//'!')
......@@ -6305,6 +6400,15 @@ SUBROUTINE read_parameter(thisHDF5File,h5path,vals)
CASE(4)
CALL read_s4(thisHDF5File,CHAR(plpath),rs4)
CALL vals%add(CHAR(plpath),rs4)
CASE(5)
CALL read_s5(thisHDF5File,CHAR(plpath),rs5)
CALL vals%add(CHAR(plpath),rs5)
CASE(6)
CALL read_s6(thisHDF5File,CHAR(plpath),rs6)
CALL vals%add(CHAR(plpath),rs6)
CASE(7)
CALL read_s7(thisHDF5File,CHAR(plpath),rs7)
CALL vals%add(CHAR(plpath),rs7)
CASE DEFAULT
CALL thisHDF5File%e%raiseWarning(modName//'::'//myName// &
' - Unsupported REAL(SSK) dimension '//str(ndims)//'!')
......
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment