Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cdo
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mpim-sw
cdo
Commits
eaecf145
Commit
eaecf145
authored
2 years ago
by
Uwe Schulzweida
Browse files
Options
Downloads
Patches
Plain Diff
Added bitinformation.h
parent
cf4a26e7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#20754
passed
2 years ago
Stage: build
Stage: check
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
src/Bitrounding.cc
+1
-10
1 addition, 10 deletions
src/Bitrounding.cc
src/Makefile.am
+1
-0
1 addition, 0 deletions
src/Makefile.am
src/bitinformation.cc
+1
-7
1 addition, 7 deletions
src/bitinformation.cc
src/bitinformation.h
+14
-0
14 additions, 0 deletions
src/bitinformation.h
with
17 additions
and
17 deletions
src/Bitrounding.cc
+
1
−
10
View file @
eaecf145
...
...
@@ -13,6 +13,7 @@
#include
"pmlist.h"
#include
"param_conversion.h"
#include
"progress.h"
#include
"bitinformation.h"
struct
BitroundParams
{
...
...
@@ -32,16 +33,6 @@ struct VarStat
int
nsbMax
=
-
1000
;
};
#define NBITS 32
struct
MutualInformation
{
double
M
[
NBITS
]
=
{
};
};
void
signed_exponent
(
float
*
A
,
size_t
n
);
MutualInformation
bitinformation
(
float
*
A
,
size_t
n
);
static
int
get_keepbits
(
MutualInformation
&
bitInfo
,
double
inflevel
)
{
...
...
This diff is collapsed.
Click to expand it.
src/Makefile.am
+
1
−
0
View file @
eaecf145
...
...
@@ -7,6 +7,7 @@ libcdo_la_SOURCES = after_dvtrans.cc \
afterburner.h
\
afterburnerlib.cc
\
bitinformation.cc
\
bitinformation.h
\
cdi_lockedIO.cc
\
cdi_lockedIO.h
\
cdi_uuid.h
\
...
...
This diff is collapsed.
Click to expand it.
src/bitinformation.cc
+
1
−
7
View file @
eaecf145
...
...
@@ -18,18 +18,12 @@
#endif
#include
"statistic.h"
// cdo::normal_inv()
constexpr
int
NBITS
=
32
;
// Number of bits in type `float`
#include
"bitinformation.h"
struct
BitpairCounters
{
int
C
[
NBITS
][
2
][
2
]
=
{
};
};
struct
MutualInformation
{
double
M
[
NBITS
]
=
{
};
};
/*
p₁ = binom_confidence(n::Int,c::Real)
...
...
This diff is collapsed.
Click to expand it.
src/bitinformation.h
0 → 100644
+
14
−
0
View file @
eaecf145
#ifndef BITINFORMATION_H
#define BITINFORMATION_H
constexpr
int
NBITS
=
32
;
// Number of bits in type `float`
struct
MutualInformation
{
double
M
[
NBITS
]
=
{
};
};
void
signed_exponent
(
float
*
A
,
size_t
n
);
MutualInformation
bitinformation
(
float
*
A
,
size_t
n
);
#endif
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