def METHOD_NAME():
    # Check for the database
    database_file = mathics_settings.DATABASES["default"]["NAME"]
    if not osp.exists(database_file):
        print("warning: database file %s not found\n" % database_file)
        if not osp.exists(DATA_DIR):
            print("Creating data directory %s" % DATA_DIR)
            os.makedirs(DATA_DIR)
    print("Migrating database %s" % database_file)
    manage_file = osp.join(osp.dirname(osp.realpath(__file__)), "manage.py")
    try:
        subprocess.check_call([sys.executable, manage_file, "migrate", "--noinput"])
        print("\ndatabase initialized sucessfully")
    except subprocess.CalledProcessError:
        print("error: failed to create database")
        sys.exit(1)