Skip to main content

No project description provided

Project description

RustSim

  • Setup your virtual environment of choice.
  • cd rustsim (home directory of this project)
  • pip install maturin
  • maturin develop
  • python
Python 3.9.16 (main, Jan 11 2023, 10:02:19) 
[Clang 14.0.6 ] :: Anaconda, Inc. on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import rustsim
>>> rustsim.run("test_set.tsv", "closures.tsv")

should yield

TermSetPairwiseSimilarity {
    set_id: "set3",
    original_subject_termset: {
        "apple",
        "orange",
        "banana",
    },
    subject_termset: {
        "fruit",
        "orange",
        "apple",
        "tropical",
        "banana",
    },
    original_object_termset: {
        "mango",
        "banana",
        "cheese",
        "papaya",
        "beef",
    },
    object_termset: {
        "mango",
        "fruit",
        "papaya",
        "banana",
        "cheese",
        "beef",
        "meat",
        "dairy",
        "tropical",
    },
    jaccard_similarity: 0.2727272727272727,
}
TermSetPairwiseSimilarity {
    set_id: "set1",
    original_subject_termset: {
        "apple",
        "orange",
        "banana",
    },
    subject_termset: {
        "fruit",
        "orange",
        "apple",
        "tropical",
        "banana",
    },
    original_object_termset: {
        "apple",
        "orange",
        "banana",
    },
    object_termset: {
        "orange",
        "banana",
        "apple",
        "tropical",
        "fruit",
    },
    jaccard_similarity: 1.0,
}
TermSetPairwiseSimilarity {
    set_id: "set2",
    original_subject_termset: {
        "apple",
        "orange",
        "banana",
    },
    subject_termset: {
        "fruit",
        "orange",
        "apple",
        "tropical",
        "banana",
    },
    original_object_termset: {
        "mango",
        "apple",
        "papaya",
    },
    object_termset: {
        "apple",
        "fruit",
        "papaya",
        "mango",
        "tropical",
    },
    jaccard_similarity: 0.42857142857142855,
}

Troubleshooting

Building for Mac ARM M1 architectures

If a import rustsim results in a ImportError warning about incompatible architecture, try the following:

  • Install conda. This guide may be helpful.
  • Set up a virtual environment with conda so that your Python build is aligned with your processor architecture (in this case, ARM). Try something like:
$ conda create -n myenv python=3.9
...setup happens...
$ conda activate myenv

and then proceed as above.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

rustsim-0.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

rustsim-0.1.0-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (564.5 kB view details)

Uploaded CPython 3.9 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

rustsim-0.1.0-cp39-cp39-macosx_10_7_x86_64.whl (288.2 kB view details)

Uploaded CPython 3.9 macOS 10.7+ x86-64

rustsim-0.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

rustsim-0.1.0-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (564.1 kB view details)

Uploaded CPython 3.8 macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

rustsim-0.1.0-cp38-cp38-macosx_10_7_x86_64.whl (288.0 kB view details)

Uploaded CPython 3.8 macOS 10.7+ x86-64

rustsim-0.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.7m manylinux: glibc 2.17+ x86-64

rustsim-0.1.0-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl (564.1 kB view details)

Uploaded CPython 3.7m macOS 10.9+ universal2 (ARM64, x86-64) macOS 10.9+ x86-64 macOS 11.0+ ARM64

rustsim-0.1.0-cp37-cp37m-macosx_10_7_x86_64.whl (288.0 kB view details)

Uploaded CPython 3.7m macOS 10.7+ x86-64

File details

Details for the file rustsim-0.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c1b055731b4c1f1ea6b48328747d06acf3bf0078cdeee94ece30b795dffe631a
MD5 fcd4e677ca2b4a8d59eb0814d07e2bae
BLAKE2b-256 5b03d55d024a074f1445151eaff84989f874e7e6b0a27ef99a0838b3f2a1f424

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp39-cp39-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 d5b575ecb5607a86ad4e3a69877ec5f2c73db804b31c89e9d41fd969ca6e60bc
MD5 a6ed0e4c3a4092fc82dde3e34a037cf5
BLAKE2b-256 96b3caf7f5149a6f979d910be7c150040a82a463a6624f84ea7315e842c51631

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp39-cp39-macosx_10_7_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp39-cp39-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 7506d8998108caa016e5d358f439dbfcc06c98752db590b6a8e4b2adbfef2208
MD5 c59d6ee8da4b2f4a4ad039ef7b5ae72a
BLAKE2b-256 03c55720b3c17b2103321334421bf353caf2d426b0119d1608c7f69e18ebb106

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1538ffb9968ac9de146d5e5923b199f59f25792a840a93157409417669db824b
MD5 d5f9b85e1e2d279c2f8fbcb59c0726ab
BLAKE2b-256 01e88f316051a60e9caef0e36fb8aed8372824d91ad79efc4453bd65b5f8da22

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp38-cp38-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 7f4bb395477887e540a92f479eeed39f512672f09d62b97503dbc1a7d7aab2f6
MD5 a0ec6ef8077a3e0f947b7396dff30f73
BLAKE2b-256 60ea2908f40ed0d41c90cbb2713b18b2b5afc102eb563736de0c9fed88a36db6

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp38-cp38-macosx_10_7_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp38-cp38-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 1d0975f25b9fe58430a868139286d1f5ba61544d88d709321c90e3c733556ee2
MD5 47559fdf4428fd1783a92840fa16647c
BLAKE2b-256 19065b52e98d7f5d0bc1e0d0cda64bed282c07f5e47674568d5f8d7b586b3856

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 66c9ff14b7df2fee9e3682ffd9c5e568a171536f592d5f5c1e19d27b8ee0ffd0
MD5 66282f69dbc6e33c6bc27f8dee4b377f
BLAKE2b-256 82ca10dba4a46482eeddc9fe663d72b60cbd7500e5a53c42bbb83d8de7ce911b

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp37-cp37m-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 6ab1fb2b1ce253799684c3b979b356c2d3e358bc77c268833d87d3bddeaeafeb
MD5 543e5f0e9af4571f01fad47543424df7
BLAKE2b-256 f3992d4ff3fad38a60283ade3cdea504bcd970644c6a8bb061305e4a185ce8cc

See more details on using hashes here.

File details

Details for the file rustsim-0.1.0-cp37-cp37m-macosx_10_7_x86_64.whl.

File metadata

File hashes

Hashes for rustsim-0.1.0-cp37-cp37m-macosx_10_7_x86_64.whl
Algorithm Hash digest
SHA256 73818f2a40ac3951ea744248ab0c190038ef81dca78ff3e62d9cae0befa45ec6
MD5 578104d55b3f316be75aebe43c6ac528
BLAKE2b-256 508a9aff7591c19c6b524fc7e70d2dc61baf56c9fe0496dd0228e658f67a4c6c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page