Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add charidotella + deps #26447

Merged
merged 30 commits into from
Jun 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
7b2db91
Add charidotella
Tobias-Fischer May 24, 2024
28b8bc0
Create LICENSE
Tobias-Fischer May 24, 2024
4466e4f
Create unvendor_commoand_line_tools.patch
Tobias-Fischer May 24, 2024
c5f4421
Add colourtime
Tobias-Fischer May 24, 2024
88fc724
Create LICENSE
Tobias-Fischer May 24, 2024
0e6b3fc
Add command_line_tools
Tobias-Fischer May 24, 2024
05a40fc
Create CMakeLists.txt for command_line_tools
Tobias-Fischer May 24, 2024
3732e90
Add event-stream
Tobias-Fischer May 24, 2024
23d60b0
Create LICENSE
Tobias-Fischer May 24, 2024
a0a84e4
Lint
Tobias-Fischer May 24, 2024
ac411fe
Lint
Tobias-Fischer May 24, 2024
e291db9
Lint
Tobias-Fischer May 24, 2024
9eca854
Lint
Tobias-Fischer May 24, 2024
f430320
Lint
Tobias-Fischer May 24, 2024
211f740
Lint
Tobias-Fischer May 24, 2024
5ce0d11
Add missing - path: CMakeLists.txt
Tobias-Fischer May 24, 2024
e3f55f7
Create build.sh
Tobias-Fischer May 24, 2024
6e14ea2
Add cmake
Tobias-Fischer May 24, 2024
6adc252
Add make
Tobias-Fischer May 24, 2024
0e22209
Add - pthread-stubs
Tobias-Fischer May 24, 2024
2d40dd0
Fix _ to -
Tobias-Fischer May 24, 2024
327d1bb
Add pthread
Tobias-Fischer May 24, 2024
a29a5a8
Rename unvendor_commoand_line_tools.patch to unvendor_command_line_to…
Tobias-Fischer May 24, 2024
eddc54d
Fix getentropy issue
Tobias-Fischer May 24, 2024
2aed950
Skip win
Tobias-Fischer May 24, 2024
662c9a2
Skip win
Tobias-Fischer May 24, 2024
e5243de
skip win
Tobias-Fischer May 24, 2024
f865bec
Update recipes/event-stream/meta.yaml
Tobias-Fischer May 24, 2024
0e698de
Delete recipes/colourtime/conda_build_config.yaml
Tobias-Fischer May 24, 2024
c9196d0
Merge branch 'main' into patch-30
xhochy Jun 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions recipes/charidotella/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 International Centre for Neuromorphic Systems

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
54 changes: 54 additions & 0 deletions recipes/charidotella/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{% set name = "charidotella" %}
{% set version = "3.1.0" %}

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/charidotella-{{ version }}.tar.gz
sha256: 1e85334280d7d9671f0b4b5c99e4a5d185180d441e3f169c64d8a0de279eff77
patches:
- unvendor_command_line_tools.patch

build:
noarch: python
script: {{ PYTHON }} -m pip install . -vv
number: 0

requirements:
host:
- python >=3.8
- setuptools
- wheel
- pip
run:
- python >=3.8
- command_line_tools
- aedat
- colourtime
- coolname
- event-stream
- jsonschema
- matplotlib-base
- pillow >=9.1
- scipy
- toml

test:
imports:
- charidotella
commands:
- pip check
requires:
- pip

about:
home: https://github.com/neuromorphicsystems/charidotella
summary: Charidotella is a toolbox to organise and visualise Event Stream (.es) recordings
license: MIT
license_file: LICENSE

extra:
recipe-maintainers:
- Tobias-Fischer
92 changes: 92 additions & 0 deletions recipes/charidotella/unvendor_command_line_tools.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
diff --git a/setup.py b/setup.py
index 41b12c0..fbf0699 100644
--- a/setup.py
+++ b/setup.py
@@ -12,72 +12,13 @@
with open(dirname / "README.md") as file:
long_description = file.read()

-executables = ["es_to_frames", "event_rate", "size", "spatiospectrogram", "spectrogram"]
-
if not "-h" in sys.argv and not "--help" in sys.argv:
- manifest_lines = [
- "include command_line_tools/source/*.hpp",
- "include command_line_tools/source/*.cpp",
- "include command_line_tools/premake4.lua",
- "include command_line_tools/third_party/pontella/source/pontella.hpp",
- "include command_line_tools/third_party/sepia/source/sepia.hpp",
- "include command_line_tools/third_party/tarsier/source/replicate.hpp",
- "include command_line_tools/third_party/tarsier/source/stitch.hpp",
- "include command_line_tools/third_party/stb_truetype.hpp",
- "include command_line_tools/third_party/monaco.ttf.base64.hpp",
- "include command_line_tools/third_party/lodepng/lodepng.h",
- "include command_line_tools/third_party/lodepng/lodepng.cpp",
- ]
+ manifest_lines = []
if "sdist" in sys.argv:
manifest_lines.append(f"include configuration-schema.json")
else:
shutil.rmtree(dirname / "charidotella" / "assets", ignore_errors=True)
(dirname / "charidotella" / "assets").mkdir()
- if sys.platform == "win32":
- subprocess.run(
- ["premake4", "vs2010"], cwd=dirname / "command_line_tools", check=True
- )
- for executable in executables:
- subprocess.run(
- [
- "C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\BuildTools\\MSBuild\\Current\\Bin\\MsBuild.exe",
- "/p:PlatformToolset=v142",
- "/property:Configuration=Release",
- f"{executable}.vcxproj",
- ],
- check=True,
- cwd=dirname / "command_line_tools" / "build",
- )
- (dirname / "charidotella" / "assets" / executable).unlink(
- missing_ok=True
- )
- shutil.copy2(
- dirname
- / "command_line_tools"
- / "build"
- / "release"
- / f"{executable}.exe",
- dirname / "charidotella" / "assets" / executable,
- )
- else:
- if not (dirname / "command_line_tools" / "build" / "Makefile").is_file():
- subprocess.run(
- ["premake4", "gmake"],
- check=True,
- cwd=dirname / "command_line_tools",
- )
- for executable in executables:
- subprocess.run(
- ["make", executable],
- check=True,
- cwd=dirname / "command_line_tools" / "build",
- )
- shutil.copy2(
- dirname / "command_line_tools" / "build" / "release" / executable,
- dirname / "charidotella" / "assets" / executable,
- )
- for executable in executables:
- manifest_lines.append(f"include charidotella/assets/{executable}")
shutil.copy2(
dirname / "configuration-schema.json",
dirname / "charidotella" / "assets" / "configuration-schema.json",
@@ -122,13 +63,6 @@
"scipy",
"toml",
],
- ext_modules=[
- setuptools.extension.Extension(
- "charidotella_extension_placeholder",
- language="cpp",
- sources=["charidotella/charidotella_extension_placeholder.c"],
- ),
- ],
entry_points={
"console_scripts": [
"charidotella = charidotella:main",
21 changes: 21 additions & 0 deletions recipes/colourtime/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 International Centre for Neuromorphic Systems

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
63 changes: 63 additions & 0 deletions recipes/colourtime/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{% set name = "colourtime" %}
{% set version = "0.4.0" %}

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/colourtime-{{ version }}.tar.gz
sha256: 3e1fe99c541dea22cd75467e0385e58551be4df953f073dcc4be2954338934b0

build:
entry_points:
- colourtime = colourtime:main
script:
- cargo-bundle-licenses --format yaml --output THIRDPARTY.yml
- {{ PYTHON }} -m pip install . --no-deps --ignore-installed -vv
number: 0
skip: true # [win]

requirements:
build:
- {{ compiler('c') }}
- {{ stdlib("c") }}
- {{ compiler('rust') }}
- python # [build_platform != target_platform]
- cross-python_{{ target_platform }} # [build_platform != target_platform]
- crossenv # [build_platform != target_platform]
- maturin >=0.14,<0.15 # [build_platform != target_platform]
- cmake
- make # [unix]
- cargo-bundle-licenses
host:
- python
- maturin >=0.14,<0.15
- pip
run:
- python
- event-stream
- matplotlib-base
- numpy
- pillow

test:
imports:
- colourtime
commands:
- pip check
- colourtime --help
requires:
- pip

about:
summary: Represent time with colours
home: https://github.com/neuromorphicsystems/colourtime
license: MIT
license_file:
- LICENSE
- THIRDPARTY.yml

extra:
recipe-maintainers:
- Tobias-Fischer
57 changes: 57 additions & 0 deletions recipes/command_line_tools/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
cmake_minimum_required(VERSION 3.10)
project(command_line_tools)

set(CMAKE_CXX_STANDARD 11)
find_package (Threads)

add_executable(crop source/crop.cpp)
target_link_libraries (crop ${CMAKE_THREAD_LIBS_INIT})
add_executable(cut source/timecode.hpp source/cut.cpp)
target_link_libraries (cut ${CMAKE_THREAD_LIBS_INIT})
add_executable(dat_to_es source/dat.hpp source/dat_to_es.cpp)
target_link_libraries (dat_to_es ${CMAKE_THREAD_LIBS_INIT})
add_executable(es_to_csv source/es_to_csv.cpp)
target_link_libraries (es_to_csv ${CMAKE_THREAD_LIBS_INIT})
add_executable(es_to_frames source/es_to_frames.cpp)
target_link_libraries (es_to_frames ${CMAKE_THREAD_LIBS_INIT})
add_executable(es_to_ply source/es_to_ply.cpp)
target_link_libraries (es_to_ply ${CMAKE_THREAD_LIBS_INIT})
add_executable(event_rate source/event_rate.cpp)
target_link_libraries (event_rate ${CMAKE_THREAD_LIBS_INIT})
add_executable(evt2_to_es source/evt2_to_es.cpp)
target_link_libraries (evt2_to_es ${CMAKE_THREAD_LIBS_INIT})
add_executable(evt3_to_es source/evt3_to_es.cpp)
target_link_libraries (evt3_to_es ${CMAKE_THREAD_LIBS_INIT})
add_executable(rainbow source/rainbow.cpp)
target_link_libraries (rainbow ${CMAKE_THREAD_LIBS_INIT})
add_executable(rainmaker source/rainmaker.cpp third_party/lodepng/lodepng.cpp)
target_link_libraries (rainmaker ${CMAKE_THREAD_LIBS_INIT})
get_target_property(PROJECT_LOCATION rainmaker BINARY_DIR)
target_compile_definitions(rainmaker PRIVATE SEPIA_COMPILER_WORKING_DIRECTORY="${PROJECT_LOCATION}")
add_executable(size source/size.cpp)
target_link_libraries (size ${CMAKE_THREAD_LIBS_INIT})
add_executable(spatiospectrogram source/spatiospectrogram.cpp)
target_link_libraries (spatiospectrogram ${CMAKE_THREAD_LIBS_INIT})
add_executable(spectrogram source/spectrogram.cpp third_party/lodepng/lodepng.cpp)
target_link_libraries (spectrogram ${CMAKE_THREAD_LIBS_INIT})
add_executable(statistics source/statistics.cpp)
target_link_libraries (statistics ${CMAKE_THREAD_LIBS_INIT})
add_executable(synth source/synth.cpp)
target_link_libraries (synth ${CMAKE_THREAD_LIBS_INIT})

install(TARGETS crop DESTINATION bin)
install(TARGETS cut DESTINATION bin)
install(TARGETS dat_to_es DESTINATION bin)
install(TARGETS es_to_csv DESTINATION bin)
install(TARGETS es_to_frames DESTINATION bin)
install(TARGETS es_to_ply DESTINATION bin)
install(TARGETS event_rate DESTINATION bin)
install(TARGETS evt2_to_es DESTINATION bin)
install(TARGETS evt3_to_es DESTINATION bin)
install(TARGETS rainbow DESTINATION bin)
install(TARGETS rainmaker DESTINATION bin)
install(TARGETS size DESTINATION bin)
install(TARGETS spatiospectrogram DESTINATION bin)
install(TARGETS spectrogram DESTINATION bin)
install(TARGETS statistics DESTINATION bin)
install(TARGETS synth DESTINATION bin)
11 changes: 11 additions & 0 deletions recipes/command_line_tools/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
mkdir build
cd build

cmake ${CMAKE_ARGS} .. \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH=$PREFIX \
-DCMAKE_INSTALL_PREFIX=$PREFIX \
-DCMAKE_INSTALL_LIBDIR=lib

cmake --build . --config Release -- -j$CPU_COUNT
cmake --build . --config Release --target install
39 changes: 39 additions & 0 deletions recipes/command_line_tools/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{% set name = "command_line_tools" %}
{% set version = "0.0.1" %}

package:
name: {{ name }}
version: {{ version }}

source:
- git_url: https://github.com/neuromorphic-paris/command_line_tools.git
- path: CMakeLists.txt

build:
number: 0
skip: true # [win]

requirements:
build:
- {{ compiler('cxx') }}
- {{ compiler('c') }}
- {{ stdlib("c") }}
- cmake
- make
- git
host:
- pthread-stubs

test:
commands:
- test -f $PREFIX/bin/event_rate

about:
home: https://github.com/neuromorphic-paris/command_line_tools
license: GPL-3.0-or-later
license_file: LICENSE.txt
summary: Command-line tools bundles command-line applications to manipulate event files.

extra:
recipe-maintainers:
- Tobias-Fischer
21 changes: 21 additions & 0 deletions recipes/event-stream/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024 International Centre for Neuromorphic Systems

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading
Loading