jl2py.jl

Transpile from Julia to Python

https://github.com/lucifer1004/jl2py.jl

Science Score: 31.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (7.5%) to scientific vocabulary

Keywords

julia python transpiler
Last synced: 6 months ago · JSON representation ·

Repository

Transpile from Julia to Python

Basic Info
  • Host: GitHub
  • Owner: lucifer1004
  • License: mit
  • Language: Julia
  • Default Branch: main
  • Homepage:
  • Size: 202 KB
Statistics
  • Stars: 17
  • Watchers: 2
  • Forks: 0
  • Open Issues: 9
  • Releases: 0
Topics
julia python transpiler
Created almost 4 years ago · Last pushed 7 months ago
Metadata Files
Readme License Citation

README.md

Jl2Py

Stable Dev Build Status Coverage

Examples

Conversion results of LeetCode.jl - 1. Two Sum

python def two_sum(nums: List[int], target: int, /) -> Union[None, Tuple[int, int]]: seen = {} for (i, n) in enumerate(nums): m = target - n if haskey(seen, m): return (seen[m], i) else: seen[n] = i

Conversion results of LeetCode.jl - 2. Add Two Numbers

python def add_two_numbers(l1: ListNode, l2: ListNode, /) -> ListNode: carry = 0 fake_head = cur = ListNode() while not isnothing(l1) or (not isnothing(l2) or not iszero(carry)): (v1, v2) = (0, 0) if not isnothing(l1): v1 = val(l1) l1 = next(l1) if not isnothing(l2): v2 = val(l2) l2 = next(l2) (carry, v) = divrem(v1 + v2 + carry, 10) next_inplace(cur, ListNode(v)) cur = next(cur) val_inplace(cur, v) return next(fake_head)

We can see that we only need to define a few polyfill functions to make the generated Python code work.

Owner

  • Name: Gabriel Wu
  • Login: lucifer1004
  • Kind: user
  • Location: Beijing, China
  • Company: @NVIDIA

DevTech Compute @ NVIDIA

Citation (CITATION.bib)

@misc{Jl2Py.jl,
	author  = {Gabriel Wu <wuzihua@pku.edu.cn> and contributors},
	title   = {Jl2Py.jl},
	url     = {https://github.com/lucifer1004/Jl2Py.jl},
	version = {v0.1.0},
	year    = {2022},
	month   = {3}
}

GitHub Events

Total
  • Delete event: 3
  • Pull request event: 5
  • Create event: 3
Last Year
  • Delete event: 3
  • Pull request event: 5
  • Create event: 3

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 7
  • Total pull requests: 17
  • Average time to close issues: about 2 months
  • Average time to close pull requests: 7 months
  • Total issue authors: 3
  • Total pull request authors: 2
  • Average comments per issue: 1.0
  • Average comments per pull request: 0.24
  • Merged pull requests: 4
  • Bot issues: 1
  • Bot pull requests: 17
Past Year
  • Issues: 0
  • Pull requests: 2
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 2
Top Authors
Issue Authors
  • lucifer1004 (5)
  • renovate[bot] (1)
  • JuliaTagBot (1)
Pull Request Authors
  • renovate[bot] (16)
  • github-actions[bot] (1)
Top Labels
Issue Labels
enhancement (3) help wanted (1) bug (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • julia 1 total
  • Total dependent packages: 1
  • Total dependent repositories: 0
  • Total versions: 6
juliahub.com: Jl2Py

Transpile from Julia to Python

  • Versions: 6
  • Dependent Packages: 1
  • Dependent Repositories: 0
  • Downloads: 1 Total
Rankings
Dependent repos count: 9.9%
Dependent packages count: 23.0%
Average: 28.9%
Stargazers count: 29.1%
Forks count: 53.5%
Last synced: 7 months ago

Dependencies

.github/workflows/CI.yml actions
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • codecov/codecov-action v3 composite
  • julia-actions/cache v1 composite
  • julia-actions/julia-buildpkg v1 composite
  • julia-actions/julia-docdeploy v1 composite
  • julia-actions/julia-processcoverage v1 composite
  • julia-actions/julia-runtest v1 composite
  • julia-actions/setup-julia v1 composite
.github/workflows/CompatHelper.yml actions
.github/workflows/TagBot.yml actions
  • JuliaRegistries/TagBot v1 composite