Create new fMRI for given experiment by uploading local file.
        Expects an tar-archive.

        Parameters
        ----------
        url : string
            Url to POST fMRI create request
        filename : string
            Path to tar-archive on local disk

        Returns
        -------
        string
            Url of created functional data resource

def create(url, filename):
        """Create new fMRI for given experiment by uploading local file.
        Expects an tar-archive.

        Parameters
        ----------
        url : string
            Url to POST fMRI create request
        filename : string
            Path to tar-archive on local disk

        Returns
        -------
        string
            Url of created functional data resource
        """
        # Upload file to create fMRI resource. If response is not 201 the
        # uploaded file is not a valid functional data archive
        files = {'file': open(filename, 'rb')}
        response = requests.post(url, files=files)
        if response.status_code != 201:
            raise ValueError('invalid file: ' + filename)
            return references_to_dict(response.json()['links'])[REF_SELF]