Install The Hdf5 Library Mac Os

Posted on

Make sure the architecture (32- vs. 64-bit) and base SDK (OS X 10.8, 10.9, or 10.10) are appropriate for your particular machine HDF5 versions If your MacPorts repositories are up to date, chances are that the hdf5 package includes a newer version. It looks like your HDF5 library is good. (Though the prefix directory specified on the configure line is “usr/local/hdf5” and.not. “/usr/local/hdf5”.) Regarding the error, there are examples in the share/ directory of the built binaries that the “make check-install” is unsuccessfully attempting to compile and run.

  1. Install The Hdf5 Library Mac Os X
  2. Install The Hdf5 Library Mac Os 11

Works on Mac OS 10.11.6, HDF5 1.8.17


  1. Download and install dependencies like zlib, openmpi. Use homebrew.
  2. Download source tarball from
  3. Configure Makefile using the following command:

This will configure a shared library HDF5 installation that uses MPI. Note that if homebrew was used to install zlib,remember to supply the proper path pointing to the zlib library.3. Compile and install HDF5.

  1. Check HDF5 installation using h5pcc --showconfig on the command line.


  1. Download and install numpy. Use pip or conda.
  2. Declare environmental variables used by h5py
  1. Configure using and install.
  1. Check the installation using the demo code on this page

To follow this lesson, you would need:

Installing the Bash Shell

The Bash Shell

Bash is a commonly-used shell that gives you the power to do simple tasks more quickly.


Video Tutorial
  1. Download the Git for Windows installer.
  2. Run the installer and follow the steps bellow:
    1. Click on 'Next'.
    2. Click on 'Next'.
    3. Keep 'Use Git from the Windows Command Prompt' selected and click on 'Next'. If you forgot to do this programs that you need for the workshop will not work properly. If this happens rerun the installer and select the appropriate option.
    4. Click on 'Next'.
    5. Keep 'Checkout Windows-style, commit Unix-style line endings' selected and click on 'Next'.
    6. Keep 'Use Windows' default console window' selected and click on 'Next'.
    7. Click on 'Install'.
    8. Click on 'Finish'.
  3. If your 'HOME' environment variable is not set (or you don't know what this is):
    1. Open command prompt (Open Start Menu then type cmd and press [Enter])
    2. Type the following line into the command prompt window exactly as shown:

      setx HOME '%USERPROFILE%'

    3. Press [Enter], you should see SUCCESS: Specified value was saved.
    4. Quit command prompt by typing exit then pressing [Enter]

This will provide you with both Git and Bash in the Git Bash program.

Mac OS X

Install The Hdf5 Library Mac Os X

The default shell in all versions of Mac OS X is Bash, so no need to install anything. You access Bash from the Terminal (found in /Applications/Utilities). See the Git installation video tutorial for an example on how to open the Terminal. You may want to keep Terminal in your dock for this workshop.


The default shell is usually Bash, but if your machine is set up differently you can run it by opening a terminal and typing bash. There is no need to install anything.

Installing Git


Git is a version control system that lets you track who made changes to what when and has options for easily updating a shared or public version of your code on You will need a supported web browser (current versions of Chrome, Firefox or Safari, or Internet Explorer version 9 or above).

You will need an account at for parts of the Git lesson. Basic GitHub accounts are free. We encourage you to create a GitHub account if you don't have one already. Please consider what personal information you'd like to reveal. For example, you may want to review these instructions for keeping your email address private provided at GitHub.


Git should be installed on your computer as part of your Bash install (described above).

Mac OS X

Video Tutorial

For OS X 10.9 and higher, install Git for Mac by downloading and running the most recent 'mavericks' installer from this list. After installing Git, there will not be anything in your /Applications folder, as Git is a command line program. For older versions of OS X (10.5-10.8) use the most recent available installer labelled 'snow-leopard' available here.


If Git is not already available on your machine you can try to install it via your distro's package manager. For Debian/Ubuntu run sudo apt-get install git and for Fedora run sudo yum install git.

Installing a Text Editor

Text Editor

When you're writing code, it's nice to have a text editor that is optimized for writing code, with features like automatic color-coding of key words. The default text editor on Mac OS X and Linux is usually set to Vim, which is not famous for being intuitive. if you accidentally find yourself stuck in it, try typing the escape key, followed by :q! (colon, lower-case 'q', exclamation mark), then hitting Return to return to the shell.


Video Tutorial

nano is a basic editor and the default that instructors use in the workshop. To install it, download the Windows installer and double click on the file to run it. This installer requires an active internet connection.

Others editors that you can use are Notepad++ or Sublime Text. Be aware that you must add its installation directory to your system path. Please ask your instructor to help you do this.

Mac OS X

nano is a basic editor and the default that instructors use in the workshop. See the Git installation video tutorial for an example on how to open nano. It should be pre-installed.

Others editors that you can use are Text Wrangler or Sublime Text.


nano is a basic editor and the default that instructors use in the workshop. It should be pre-installed.

Others editors that you can use are Gedit, Kate or Sublime Text.

Installing Python Using Anaconda

Python is a popular language for scientific computing, and great forgeneral-purpose programming as well. Installing all of its scientific packagesindividually can be a bit difficult, however, so we recommend the all-in-oneinstaller Anaconda.

Regardless of how you choose to install it, please make sure you install Pythonversion 3.6. Also, please set up your python environment at least a day in advance of the workshop. If you encounter problems with the installation procedure, ask your workshop organizers via e-mail for assistance soyou are ready to go as soon as the workshop begins.

Windows - Video tutorial

  1. Open your web browser.

  2. Download the Python 3 installer for Windows.

  3. Double-click the executable and install Python 3 using MOST of thedefault settings. The only exception is to check the Make Anaconda the default Python option.

Mac OS X - Video tutorial

  1. Open your web browser.

  2. Download the Python 3 installer for OS X.

  3. Install Python 3 using all of the defaults for installation.


Note that the following installation steps require you to work from the shell. If you run into any difficulties, please request help before the workshop begins.

  1. Open with your web browser.

  2. Download the Python 3 installer for Linux.

  3. Install Python 3 using all of the defaults for installation.

    a. Open a terminal window.

    b. Navigate to the folder where you downloaded the installer

    c. Type

    and press tab. The name of the file you just downloaded should appear.

    d. Press enter.

    e. Follow the text-only prompts. When the license agreement appears (a colon will be present at the bottom of the screen) hold the down arrow until the bottom of the text. Type yes and press enter to approve the license. Press enter again to approve the default location for the files. Type yes and press enter to prepend Anaconda to your PATH (this makes the Anaconda distribution the default Python).

Getting the Data

The data we will be using is a small dataset created for this lesson. To obtain it, download and unzip the file metos-python-data.tar.

In order to follow the presented material, you should launch a Jupyter notebook in the root directory (see Starting Python).

Starting Python

We will teach Python using the Jupyter notebook, a programming environment that runs in a web browser. Jupyter requires a reasonably up-to-date browser, preferably a current version of Chrome, Safari, or Firefox (note that Internet Explorer version 9 and below are not supported). If you installed Python using Anaconda, Jupyter should already be on your system. If you did not use Anaconda, use the Python package manager pip(see the Jupyter website for details.)

To start the notebook, open a terminal or git bash and type the command:

To start the Python interpreter without the notebook, open a terminal or Git Bash and type the command:

Installing additional Python libraries Using Anaconda

To install additional Python packages/libraries, you need to open a Terminal, and then follow the instructions below.


For Windows, Linux and Mac OS X:


We will be using HDF5 python library and for Windows, Linux and Mac OS X:

Geospatial Data Abstraction Library (GDAL)

Install The Hdf5 Library Mac Os 11

GDAL is a library for reading/writing raster and vector geospatial data formats.

matplotlib and basemap



Animation ffmpeg


scipy, scikit-image and scikit-learn

xarray and dask

Install hdf5 python

cartopy, holoviews, datashader and dill

ipyleaflet and gmaps