Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
prodigy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Tobias Winkler
prodigy
Commits
0b01bc6c
Commit
0b01bc6c
authored
3 years ago
by
Lutz Klinkenberg
Browse files
Options
Downloads
Patches
Plain Diff
name changed to pgyin
parent
1d07b893
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
CMakeLists.txt
+4
-4
4 additions, 4 deletions
CMakeLists.txt
python/bindings.cpp
+2
-2
2 additions, 2 deletions
python/bindings.cpp
python/test.py
+3
-3
3 additions, 3 deletions
python/test.py
setup.py
+4
-4
4 additions, 4 deletions
setup.py
test/TestEquivalence.cpp
+1
-1
1 addition, 1 deletion
test/TestEquivalence.cpp
with
14 additions
and
14 deletions
CMakeLists.txt
+
4
−
4
View file @
0b01bc6c
cmake_minimum_required
(
VERSION 3.4...3.18
)
set
(
CMAKE_MODULE_PATH
${
CMAKE_MODULE_PATH
}
"
${
CMAKE_SOURCE_DIR
}
/cmake/modules/"
)
project
(
p
rodigy
)
project
(
p
ygin
)
set
(
CMAKE_CXX_STANDARD 14
)
...
...
@@ -21,6 +21,6 @@ add_subdirectory(test)
# python bindings
add_subdirectory
(
lib/pybind11
)
pybind11_add_module
(
p
rodigy
python/bindings.cpp
)
target_link_libraries
(
p
rodigy
PUBLIC
${
CMAKE_PROJECT_NAME
}
_lib
)
target_compile_definitions
(
p
rodigy
PRIVATE VERSION_INFO=
${
EXAMPLE_VERSION_INFO
}
)
pybind11_add_module
(
p
ygin
python/bindings.cpp
)
target_link_libraries
(
p
ygin
PUBLIC
${
CMAKE_PROJECT_NAME
}
_lib
)
target_compile_definitions
(
p
ygin
PRIVATE VERSION_INFO=
${
EXAMPLE_VERSION_INFO
}
)
This diff is collapsed.
Click to expand it.
python/bindings.cpp
+
2
−
2
View file @
0b01bc6c
...
...
@@ -26,8 +26,8 @@ string toString(const Dist& dist){
namespace
py
=
pybind11
;
PYBIND11_MODULE
(
p
rodigy
,
m
)
{
m
.
doc
()
=
"python bindings of p
rodigy
- a library for manipulating distributions through generating functions"
;
PYBIND11_MODULE
(
p
ygin
,
m
)
{
m
.
doc
()
=
"python bindings of p
ygin
- a library for manipulating distributions through generating functions"
;
py
::
class_
<
Dist
>
(
m
,
"Dist"
)
.
def
(
py
::
init
())
...
...
This diff is collapsed.
Click to expand it.
python/test.py
+
3
−
3
View file @
0b01bc6c
import
p
rodigy
import
p
ygin
if
__name__
==
"
__main__
"
:
dist
=
p
rodigy
.
geometric
(
"
x
"
,
"
1/2
"
)
dist
=
p
ygin
.
geometric
(
"
x
"
,
"
1/2
"
)
print
(
dist
.
E
(
"
x
"
))
dist
=
p
rodigy
.
Dist
(
"
1
"
);
dist
=
p
ygin
.
Dist
(
"
1
"
);
This diff is collapsed.
Click to expand it.
setup.py
+
4
−
4
View file @
0b01bc6c
...
...
@@ -123,14 +123,14 @@ class CMakeBuild(build_ext):
# The information here can also be placed in setup.cfg - better separation of
# logic and declaration, and simpler if you include description/version in a file.
setup
(
name
=
"
p
rodigy
"
,
name
=
"
p
ygin
"
,
version
=
"
1.0
"
,
author
=
"
Tobias Winkler
"
,
author_email
=
"
tobias.winkler@cs.rwth-aachen.de
"
,
description
=
"
python bindings of p
rodigy
"
,
description
=
"
python bindings of p
ygin
"
,
long_description
=
""
,
ext_modules
=
[
CMakeExtension
(
"
p
rodigy
"
)],
ext_modules
=
[
CMakeExtension
(
"
p
ygin
"
)],
cmdclass
=
{
"
build_ext
"
:
CMakeBuild
},
zip_safe
=
False
,
extras_require
=
{
"
test
"
:
[
"
pytest
"
]},
)
\ No newline at end of file
)
This diff is collapsed.
Click to expand it.
test/TestEquivalence.cpp
+
1
−
1
View file @
0b01bc6c
...
...
@@ -304,7 +304,7 @@ TEST(EquivalenceCheck, dep_bern){
l4
=
l4
.
update
(
"n"
,
"n-t"
);
l5
=
l4
.
update
(
"c"
,
"0"
);
l6
=
l5
.
update
(
"t"
,
"0"
);
l7
=
l6
+
(
l0
-
l1
);
l7
=
l6
+
l0
.
filterLeq
(
"c"
,
"0"
);
Dist
res1
=
l7
;
/*
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment