Skip to main content

Frictionless Darwin Core

A tool converting Darwin Core Archive into Frictionless Data Package.

Features

  • datapackage.json: Ensure your DarwinCore archive complies with Frictionless specifications
  • README.md: Add human readable metadata from EML
  • Support all standards DarwinCore terms
  • Support default values in DarwinCore schema
  • Fields constraints: Enable further data validation, with goodtables
  • URL: Accept DarwinCore Archive from local path or URL
  • Command line interface

Contents

Getting Started

Installing

pip install FrictionlessDarwinCore

Running on CLI

fdwca --help
Usage: fdwca [OPTIONS] DWCA OUTPATH

Options:
  -f, --format [json|md|csv]  Output format
  --help                  Show this message and exit.

# convert from local DwC archive
fdwca myDwC.zip myDP.zip

# convert from URL (archive accessible on internet)
fdwca https://ipt.biodiversity.be/archive.do?r=rbins_saproxilyc_beetles S1dp.zip

# only generates JSON descriptor (datapackage.json)
fdwca -f json https://ipt.biodiversity.be/archive.do?r=rbins_saproxilyc_beetles datapackage.json

# only generates markdown human readable metadata (readme.md)
fdwca -f md https://ipt.biodiversity.be/archive.do?r=rbins_saproxilyc_beetles readme.md

# only converts data as zipped CSV files
fdwca -f csv https://ipt.biodiversity.be/archive.do?r=rbins_saproxilyc_beetles beetles.zip

Python use

Alternatively, you can use DwCArchive Python object like this:

from FrictionlessDarwinCore import DwCArchive

# load DarwinCore archive from URL
da = DwCArchive('https://ipt.biodiversity.be/archive.do?r=rbins_saproxilyc_beetles')
# infer Data Package structure from DarwinCore files
da.infer()
if da.valid:
  # save it as Data Package locally
  da.save('BeetlesDP.zip')
  # ... or generates separate JSON descriptor
  da.to_json('datpackage.json')
  # ... or generates separate markdown human readable metadata
  da.to_markdown('readme.md')
  # ... or generated zip with data files only
  da.to_csv('data.zip')

Documentation

Rationale

DarwinCore standard, created and maintained by Biodivesity Informatics Standards(aka TDWG), is used to publish Life Sciences data about observations, collections specimens, species checklists and sampling events. DarwinCore Archive(DwCA), a bundle of biodiversity data and metadata files, is well established mechanism for publishing or using data in Global Biodiversity Information Facility and other Life Sciences networks.

Frictionless Data Package is an emerging, domain agnostic, data standard that offers a variety of cross technology tools.

Bridging these two data ecosystems is our vision. This project is supported by Open Knowledge Foundation and funded under the Frictionless Data Tool Fund.

What it does?

DarwinCore archives consist of:

  • a core data file
  • optionally, 1 or more extension data file(s)
  • eml.xml: metadata written in Ecological Metadata Language
  • meta.xml: the structure of the DarwinCore data files

Basically, this conversion tool appends two files to the archive, see diagram below:

  • datapackage.json: data package descriptor of the data files
  • readme.md: markdown, human readable, metadata
┌─────────────────────────────────────────────────────────────────┐
│   ┌──────────────────────────────────────────────────────────┐  │
│   │DarwinCore Archive                                        │  │
│   │                                                          │  │
│   │                                ┌ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │                           ┌ ─ ─    Extension 1    │      │  │
│   │                                └ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │    ┌──────────────────┐   │    ┌ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │    │    Core file     │─ ─ ─ ─     Extension 2    │      │  │
│   │    └──────────────────┘   │    └ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │                                                          │  │
│   │                           │                              │  │
│   │                                ┌ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │                           └ ─ ─    Extension n    │      │  │
│   │                                └ ─ ─ ─ ─ ─ ─ ─ ─ ─       │  │
│   │                                                          │  │
│   │   ┌──────────────────┐         ┌──────────────────┐      │  │
│   │   │     meta.xml     │         │     eml.xml      │      │  │
│   │   └──────────────────┘         └──────────────────┘      │  │
│   │             │                            │               │  │
│   └─────────────┼────────────────────────────┼───────────────┘  │
│                 ▼                            ▼                  │
│       ┌──────────────────┐         ┌──────────────────┐         │
│       │ datapackage.json │         │    readme.md     │         │
│       └──────────────────┘         └──────────────────┘         │
│                                                                 │
│                                           FrictionlessDarwinCore│
│                                                  (=Data Package)│
└─────────────────────────────────────────────────────────────────┘

The tool can also generate these two files as separate outputs without touching the archive.

Additionally, the tool also converts the Core and Extension(s) files, when needed.

DarwinCore terms

Darwin Core is a very persmissive standard some recommandations but almost no constraining rules. This table assigns Frictionless Data Package's type, format and constraints to every Darwin Core term. Values that do not comply with these Frictionless DarwinCore rules will automatically raise warnings.

Test cases suite

The initial test cases suite covers a wide variety of Darwin Core usages. It should give enough confidence that basic incompatibilities are identified, reported and solved but it will not guarantee that all possible DwC Archives will automatically translate into valid Data Packages.

Contributing

You are encouraged to contribute by identifying/reporting issues or incompatiblities and helping to solve them.

Not familiar with Darwin Core?

Have a look at these online documents:

Metadata

Release files for FrictionlessDarwinCore 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for FrictionlessDarwinCore 1.0.0
File Size Uploaded Provenance Actions
FrictionlessDarwinCore-1.0.0.tar.gz 1.7 MB Without provenance Details for FrictionlessDarwinCore-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for FrictionlessDarwinCore 1.0.0
File Interpreter ABI Platform Actions
FrictionlessDarwinCore-1.0.0-py3-none-any.whl Python 3 none any Details for FrictionlessDarwinCore-1.0.0-py3-none-any.whl

Total release size: 3.4 MB

Release files / FrictionlessDarwinCore-1.0.0.tar.gz

Download URL FrictionlessDarwinCore-1.0.0.tar.gz
Size 1.7 MB
Tags Source
SHA-256 checksum
How to use checksums
9dedee91417606edbb20ea19b95cb4497f35311f68d1b48715ad48d0be6645ba
BLAKE2b-256 checksum
How to use checksums
24e85db6740007d5a727d09bc965bd320e31880819a14ce00d3d1f94875f84a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

Release files / FrictionlessDarwinCore-1.0.0-py3-none-any.whl

Download URL FrictionlessDarwinCore-1.0.0-py3-none-any.whl
Size 1.7 MB
Tags Python 3
SHA-256 checksum
How to use checksums
31d52377441406193df7cf1b00746c45135770a5ce1ed5cb405cc58edc35bd34
BLAKE2b-256 checksum
How to use checksums
80cb2a88a4cf8cbf9bd0518e4d6cdd1db3e59e290c75c303552e53c91b485da8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

Security for FrictionlessDarwinCore 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page