summaryrefslogtreecommitdiffstats
path: root/develop/_l_b_quiz_answers.html
diff options
context:
space:
mode:
authorbyrnHDF <byrnHDF@users.noreply.github.com>2023-11-16 13:49:28 (GMT)
committerbyrnHDF <byrnHDF@users.noreply.github.com>2023-11-16 13:49:28 (GMT)
commit4f20d880c97be1249f8d89ced95f72836dbf3ee0 (patch)
tree30d8dcb282134b7126b092796f2be00d2d97bd3c /develop/_l_b_quiz_answers.html
parent4e7e457497c948b41c8b0065225875bf10cdf9d4 (diff)
downloadhdf5-4f20d880c97be1249f8d89ced95f72836dbf3ee0.zip
hdf5-4f20d880c97be1249f8d89ced95f72836dbf3ee0.tar.gz
hdf5-4f20d880c97be1249f8d89ced95f72836dbf3ee0.tar.bz2
deploy: ef39882fa1e13740d2530c7a0637bd1f1a822b68
Diffstat (limited to 'develop/_l_b_quiz_answers.html')
-rw-r--r--develop/_l_b_quiz_answers.html282
1 files changed, 282 insertions, 0 deletions
diff --git a/develop/_l_b_quiz_answers.html b/develop/_l_b_quiz_answers.html
new file mode 100644
index 0000000..524d4ed
--- /dev/null
+++ b/develop/_l_b_quiz_answers.html
@@ -0,0 +1,282 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
+<meta http-equiv="X-UA-Compatible" content="IE=9"/>
+<meta name="generator" content="Doxygen 1.9.1"/>
+<meta name="viewport" content="width=device-width, initial-scale=1"/>
+<title>HDF5: Learning the basics QUIZ with Answers</title>
+<link href="tabs.css" rel="stylesheet" type="text/css"/>
+<script type="text/javascript" src="jquery.js"></script>
+<script type="text/javascript" src="dynsections.js"></script>
+<link href="navtree.css" rel="stylesheet" type="text/css"/>
+<script type="text/javascript" src="resize.js"></script>
+<script type="text/javascript" src="navtreedata.js"></script>
+<script type="text/javascript" src="navtree.js"></script>
+<link href="search/search.css" rel="stylesheet" type="text/css"/>
+<script type="text/javascript" src="search/searchdata.js"></script>
+<script type="text/javascript" src="search/search.js"></script>
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+ $(document).ready(function() { init_search(); });
+/* @license-end */
+</script>
+<link href="doxygen.css" rel="stylesheet" type="text/css" />
+<link href="hdf5doxy.css" rel="stylesheet" type="text/css">
+<!-- <link href="hdf5doxy.css" rel="stylesheet" type="text/css"/>
+ -->
+<script type="text/javascript" src="hdf5_navtree_hacks.js"></script>
+</head>
+<body>
+<div style="background:#FFDDDD;font-size:120%;text-align:center;margin:0;padding:5px">Please, help us to better serve our user community by answering the following short survey: <a href="https://www.hdfgroup.org/website-survey/">https://www.hdfgroup.org/website-survey/</a></div>
+<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
+<div id="titlearea">
+<table cellspacing="0" cellpadding="0">
+ <tbody>
+ <tr style="height: 56px;">
+ <td id="projectlogo"><img alt="Logo" src="HDFG-logo.png"/></td>
+ <td id="projectalign" style="padding-left: 0.5em;">
+ <div id="projectname"><a href="https://www.hdfgroup.org">HDF5</a>
+ &#160;<span id="projectnumber">1.15.0.ef39882</span>
+ </div>
+ <div id="projectbrief">API Reference</div>
+ </td>
+ <td> <div id="MSearchBox" class="MSearchBoxInactive">
+ <span class="left">
+ <img id="MSearchSelect" src="search/mag_sel.svg"
+ onmouseover="return searchBox.OnSearchSelectShow()"
+ onmouseout="return searchBox.OnSearchSelectHide()"
+ alt=""/>
+ <input type="text" id="MSearchField" value="Search" accesskey="S"
+ onfocus="searchBox.OnSearchFieldFocus(true)"
+ onblur="searchBox.OnSearchFieldFocus(false)"
+ onkeyup="searchBox.OnSearchFieldChange(event)"/>
+ </span><span class="right">
+ <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
+ </span>
+ </div>
+</td>
+ </tr>
+ </tbody>
+</table>
+</div>
+<!-- end header part -->
+<!-- Generated by Doxygen 1.9.1 -->
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
+/* @license-end */
+</script>
+</div><!-- top -->
+<div id="side-nav" class="ui-resizable side-nav-resizable">
+ <div id="nav-tree">
+ <div id="nav-tree-contents">
+ <div id="nav-sync" class="sync"></div>
+ </div>
+ </div>
+ <div id="splitbar" style="-moz-user-select:none;"
+ class="ui-resizable-handle">
+ </div>
+</div>
+<script type="text/javascript">
+/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
+$(document).ready(function(){initNavTree('_l_b_quiz_answers.html',''); initResizable(); });
+/* @license-end */
+</script>
+<div id="doc-content">
+<!-- window showing the filter options -->
+<div id="MSearchSelectWindow"
+ onmouseover="return searchBox.OnSearchSelectShow()"
+ onmouseout="return searchBox.OnSearchSelectHide()"
+ onkeydown="return searchBox.OnSearchSelectKey(event)">
+</div>
+
+<!-- iframe showing the search results (closed by default) -->
+<div id="MSearchResultsWindow">
+<iframe src="javascript:void(0)" frameborder="0"
+ name="MSearchResults" id="MSearchResults">
+</iframe>
+</div>
+
+<div class="PageDoc"><div class="header">
+ <div class="headertitle">
+<div class="title">Learning the basics QUIZ with Answers </div> </div>
+</div><!--header-->
+<div class="contents">
+<div class="textblock"><p>Navigate back: <a class="el" href="index.html">Main</a> / <a class="el" href="_getting_started.html">Getting Started with HDF5</a> / <a class="el" href="_learn_basics.html">Learning the Basics</a> </p><hr />
+<p><a class="el" href="_l_b_file_org.html">HDF5 File Organization</a> </p><ol>
+<li>
+Name and describe the two primary objects that can be stored in an HDF5 file. <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>Group: A grouping structure containing zero or more HDF5 objects, together with supporting metadata.<br />
+ Dataset: A multidimensional array of data elements, together with supporting metadata. </td></tr>
+</table>
+</li>
+<li>
+What is an attribute? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>An HDF5 attribute is a user-defined HDF5 structure that provides extra information about an HDF5 object. </td></tr>
+</table>
+</li>
+<li>
+Give the path name for an object called <code style="background-color:whitesmoke;">harry</code> that is a member of a group called <code style="background-color:whitesmoke;">dick</code>, which, in turn, is a member of the root group. <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>/dick/harry </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_a_p_i.html">The HDF5 API</a> </p><ol>
+<li>
+Describe the purpose of each of the following HDF5 APIs: <div class="fragment"><div class="line">H5A, H5D, H5E, H5F, H5G, H5T, H5Z </div>
+</div><!-- fragment --> <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>H5A: Attribute access and manipulation routines <br />
+ H5D: Dataset access and manipulation routines <br />
+ H5E: Error handling routines H5F: File access routines <br />
+ H5G: Routines for creating and operating on groups <br />
+ H5T: Routines for creating and manipulating the datatypes of dataset elements <br />
+ H5Z: Data compression routines </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_file_create.html">Creating an HDF5 File</a> </p><ol>
+<li>
+What two HDF5 routines must be called to create an HDF5 file? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td><a class="el" href="group___h5_f.html#gae64b51ee9ac0781bc4ccc599d98387f4" title="Creates an HDF5 file.">H5Fcreate</a> and <a class="el" href="group___h5_f.html#gac55cd91d80822e4f8c2a7f04ea71b124" title="Terminates access to an HDF5 file.">H5Fclose</a>. </td></tr>
+</table>
+</li>
+<li>
+What include file must be included in any file that uses the HDF5 library? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>hdf5.h must be included because it contains definitions and declarations used by the library. </td></tr>
+</table>
+</li>
+<li>
+An HDF5 file is never completely empty because as soon as it is created, it automatically contains a certain primary object. What is that object? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>The root group. </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_dset_create.html">Creating a Dataset</a> </p><ol>
+<li>
+Name and describe two major datatype categories. <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>Atomic datatype: An atomic datatype cannot be decomposed into smaller units at the API level. <br />
+ Compound datatype: A compound datatype is a collection of atomic and compound datatypes, or small arrays of such types. </td></tr>
+</table>
+</li>
+<li>
+List the HDF5 atomic datatypes. Give an example of a predefined datatype. How would you create a string dataset? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>There are six HDF5 atomic datatypes: integer, floating point, date and time, character string, bit field, and opaque. <br />
+ Examples of predefined datatypes include the following:<br />
+ <ul>
+<li><a class="el" href="group___p_d_t_i_e_e_e.html#ga994ce9ffdd2c77a9352b102a883503ea">H5T_IEEE_F32LE</a> - 4-byte little-endian, IEEE floating point </li>
+<li><a class="el" href="group___p_d_t_n_a_t.html#ga3cf93ffc6782be68070ef8e00f219ec2">H5T_NATIVE_INT</a> - native integer</li>
+</ul>
+You would create a string dataset with the <a class="el" href="group___p_d_t_s.html#ga7f6b6959fefe56d2e871659110936d2d">H5T_C_S1</a> datatype, and set the size of the string with the <a class="el" href="group___h5_t.html#gae5f38bfd4a4c557496b3194b5180212c" title="Sets size for a datatype.">H5Tset_size</a> call. </td></tr>
+</table>
+</li>
+<li>
+What does the dataspace describe? What are the major characteristics of the simple dataspace? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>The dataspace describes the dimensionality of the dataset. A simple dataspace is characterized by its rank and dimension sizes. </td></tr>
+</table>
+</li>
+<li>
+What information needs to be passed to the <a class="el" href="group___h5_d.html#ga0647ba4bbd26d5230cc07f3a5685b2cf">H5Dcreate</a> function, i.e., what information is needed to describe a dataset at creation time? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>The dataset location, name, dataspace, datatype, and dataset creation property list. </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_dset_r_w.html">Reading From and Writing To a Dataset</a> </p><ol>
+<li>
+What are six pieces of information which need to be specified for reading and writing a dataset? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>The dataset identifier, the dataset's datatype and dataspace in memory, the dataspace in the file, the dataset transfer property list, and a data buffer. </td></tr>
+</table>
+</li>
+<li>
+Why are both the memory dataspace and file dataspace needed for read/write operations, while only the memory datatype is required? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>A dataset's file datatype is not required for a read/write operation because the file datatype is specified when the dataset is created and cannot be changed. Both file and memory dataspaces are required for dataset subsetting and for performing partial I/O operations. </td></tr>
+</table>
+</li>
+<li>
+In Figure 6.1, what does this line mean? <div class="fragment"><div class="line">DATASPACE { SIMPLE (4 , 6 ) / ( 4 , 6 ) }</div>
+</div><!-- fragment --> <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>It means that the dataset dset has a simple dataspace with the current dimensions (4,6) and the maximum size of the dimensions (4,6). </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_attr_create.html">Creating an Attribute</a> </p><ol>
+<li>
+What is an attribute? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>An attribute is a dataset attached to an object. It describes the nature and/or the intended usage of the object. </td></tr>
+</table>
+</li>
+<li>
+Can partial I/O operations be performed on attributes? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>No. </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_grp_create.html">Creating an Group</a> </p><ol>
+<li>
+What are the two primary objects that can be included in a group? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>A group and a dataset. </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_grp_create_names.html">Creating Groups using Absolute and Relative Names</a> </p><ol>
+<li>
+Group names can be specified in two ways. What are these two types of group names? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>Relative and absolute. </td></tr>
+</table>
+</li>
+<li>
+You have a dataset named <code style="background-color:whitesmoke;">moo</code> in the group <code style="background-color:whitesmoke;">boo</code>, which is in the group <code style="background-color:whitesmoke;">foo</code>, which, in turn, is in the <code style="background-color:whitesmoke;">root</code> group. How would you specify an absolute name to access this dataset? <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>/foo/boo/moo </td></tr>
+</table>
+</li>
+</ol>
+<p><a class="el" href="_l_b_grp_dset.html">Creating Datasets in Groups</a> </p><ol>
+<li>
+Describe a way to access the dataset moo described in the previous section (question 2) using a relative name. Describe a way to access the same dataset using an absolute name. <table class="doxtable">
+<tr>
+<th><b>Answer</b> </th><td>Access the group /foo and get the group ID. Access the group boo using the group ID obtained in Step 1. Access the dataset moo using the group ID obtained in Step 2. <div class="fragment"><div class="line">gid = <a class="code" href="group___h5_g.html#ga3eca6807deff4f9e51fc5fe0befc2245">H5Gopen</a> (file_id, <span class="stringliteral">&quot;/foo&quot;</span>, 0); <span class="comment">/* absolute path */</span> </div>
+<div class="line">gid1 = <a class="code" href="group___h5_g.html#ga3eca6807deff4f9e51fc5fe0befc2245">H5Gopen</a> (gid, <span class="stringliteral">&quot;boo&quot;</span>, 0); <span class="comment">/* relative path */</span> </div>
+<div class="line">did = <a class="code" href="_h5version_8h.html#a7dba2e5b2045f31c0932123ffb54f7a3">H5Dopen</a> (gid1, <span class="stringliteral">&quot;moo&quot;</span>); <span class="comment">/* relative path */</span> </div>
+<div class="ttc" id="a_h5version_8h_html_a7dba2e5b2045f31c0932123ffb54f7a3"><div class="ttname"><a href="_h5version_8h.html#a7dba2e5b2045f31c0932123ffb54f7a3">H5Dopen</a></div><div class="ttdeci">#define H5Dopen</div><div class="ttdef"><b>Definition:</b> H5version.h:903</div></div>
+<div class="ttc" id="agroup___h5_g_html_ga3eca6807deff4f9e51fc5fe0befc2245"><div class="ttname"><a href="group___h5_g.html#ga3eca6807deff4f9e51fc5fe0befc2245">H5Gopen</a></div><div class="ttdeci">#define H5Gopen</div><div class="ttdef"><b>Definition:</b> H5version.h:1008</div></div>
+</div><!-- fragment --> Access the group /foo and get the group ID. Access the dataset boo/moo with the group ID just obtained. <div class="fragment"><div class="line">gid = <a class="code" href="group___h5_g.html#ga3eca6807deff4f9e51fc5fe0befc2245">H5Gopen</a> (file_id, <span class="stringliteral">&quot;/foo&quot;</span>, 0); <span class="comment">/* absolute path */</span> </div>
+<div class="line">did = <a class="code" href="_h5version_8h.html#a7dba2e5b2045f31c0932123ffb54f7a3">H5Dopen</a> (gid, <span class="stringliteral">&quot;boo/moo&quot;</span>); <span class="comment">/* relative path */</span> </div>
+</div><!-- fragment --> Access the dataset with an absolute path. <div class="fragment"><div class="line">did = <a class="code" href="_h5version_8h.html#a7dba2e5b2045f31c0932123ffb54f7a3">H5Dopen</a> (file_id, <span class="stringliteral">&quot;/foo/boo/moo&quot;</span>); <span class="comment">/* absolute path */</span></div>
+</div><!-- fragment --> </td></tr>
+</table>
+</li>
+</ol>
+<hr />
+<p> Navigate back: <a class="el" href="index.html">Main</a> / <a class="el" href="_getting_started.html">Getting Started with HDF5</a> / <a class="el" href="_learn_basics.html">Learning the Basics</a> </p>
+</div></div><!-- contents -->
+</div><!-- PageDoc -->
+</div><!-- doc-content -->
+<!-- start footer part -->
+<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
+ <ul>
+ <li class="footer">Generated by
+ <a href="http://www.doxygen.org/index.html">
+ <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
+ </ul>
+</div>
+</body>
+</html>