99.General - YukaKoshiba/MyknowledgeDocs GitHub Wiki

Geneeal @English Version
Create Date:2025/07/10
Last Update Date:2025/07/10

Contents

1.File Formats
2.Images
3.Audio:
Representation Format  Resolution  Sobel Operator  JPEG Byte Pattern
4.Japanese/Western Calendar Conversion
5.Color Models
6.Computer Science (CS)
7.Information Technology (IT)
API
8.File Paths 9.XBRL

1. File Formats

(Reference) List of Extensions

Document Files

File Format Description Notes
.csv Abbreviation for Comma Separated Value
A text file where values are delimited by commas (,)
Can be opened with Notepad, Excel, etc.
If the character encoding is UTF-8, characters may be corrupted when opened with Excel.
.xlsx File generated by Microsoft Excel
Previously .xls, migrated in 2007
Use .xlsm if macros are included
.json Designed for data exchange on the Web
.zip A file containing multiple compressed files to reduce occupied space

2. Images

Representation Methods

  • Raster format
    Represents images using dots (pixels)
    To improve image quality, the number of dots must be increased (=resolution must be increased), which also increases data size.
    Images tend to degrade with repeated editing, and file sizes tend to become large.  
    • Bitmap format
      A type of raster format that records pixel information as a collection of bits.
      Common bitmap formats include .bmp files, which are standard in Windows.
      Fundamentals of BITMAP format
      ・Pixel Representation: Images are represented as a collection of small dots (pixels), and each pixel has color information (usually RGB values).
      ・Raster Format: BITMAP is a raster image format; image quality degrades when magnified as pixels become coarser.
      ・.BMP File: The extension for common BITMAP files in Windows is .bmp.
      Metadata
      ・BITMAPFILEHEADER (File Header)
      Stores basic information about the entire file, such as file type, file size, and the starting position of image data.
      14 bytes
      ・BITMAPINFOHEADER (Information Header)
      Stores detailed image information such as image width, height, color depth, and compression format.
      40 bytes
      ・RGBQUAD (Color Palette)
      For indexed color images, stores information indicating the correspondence between each pixel's value and its actual color.
      ・Bit Fields
      This header is necessary if pixel data is stored in bit field format.
      Stores color mask values for each color component to obtain information on which bits of the pixel data correspond to which color.
  • Vector format
    Records 2D information such as images and text as numerical values, which the browser renders on the fly.
    No need to worry about resolution, and data does not degrade with scaling.
File Format Compression Transparency File Size Usage on Websites Optimal Use Rendering Method Full Name
.jpg Lossy compression
※Degrades with each compression
Light Photos Raster format Joint Photographic Experts Group
.png Heavy ※Depends on case Photos △
Logos and text images 〇
Logos, graphs, text images Raster format Portable Network Graphics
.svg Also supports video Less likely to be heavy compared to .jpeg/.png Good compatibility with responsive design Icons, maps, flat illustrations, animations Vector format Scalable Vector Graphics
※Both .jpg and .png can be used for printed materials, but the beauty of printed materials is determined by resolution, not extension.
※.svg allows easy changes to color, size, and text later, and can also improve web page responsiveness.
※.svg also supports animation and can utilize transparency not available with traditional GIFs.

Resolution

The precision of an image quantified by the density of dots per 1 inch (2.54cm).
The unit is "dpi", short for dot per inch.
Higher resolution means a finer, smoother image expression and a clearer appearance even when magnified.

Optimal resolution by use case

Use Case Optimal Resolution
Web Page 71~96dpi
Brochure 300~350dpi
Poster 200dpi

Sobel Operator

An important tool for edge detection in image processing.
Used to emphasize and detect areas of significant luminance change in an image, i.e., edges.

Performs a convolution operation on the image.
Specifically, it calculates the difference in luminance values between each pixel and its surrounding pixels.
The larger the difference, the higher the likelihood of it being an edge.
There are two types of filters: one for detecting horizontal edges and one for detecting vertical edges.
By combining these filters, edges in all directions can be detected.

Application examples of the Sobel operator
・Image recognition: Extracts object outlines to improve image recognition accuracy.
・Medical image processing: Extracts outlines of lesions and organs from medical images such as CT and MRI.
・Motion detection: Detects object movement in videos, used in surveillance systems, etc.

Reference

JPEG Byte Pattern

While JPEG is more complex than BMP, it has a byte pattern called a signature that distinguishes it from other file formats.

The first three bytes of a JPEG are `0xff 0xd8 0xff`.

From the 4th byte onwards, they are `0xe0, 0xe1, 0xe2, 0xe3, 0xe4, 0xe5, 0xe6, 0xe7, 0xe8, 0xe9, 0xea, 0xeb, 0xec, 0xed, 0xee, 0xef`
Common to these is that they are numbers starting with 0xe + a hexadecimal digit,
which means they start with 0ex(16) → 14(10) → 1110(2).

3. Audio

List of Audio File Formats
File Format Storage Format Contained Information Volume
.wav Stores audio as a sequence of samples 44-byte header information
Includes information about the file itself, such as file size, samples per second, and size of each sample.
Following the header is a sequence of samples,
each sample representing an audio signal at a specific point in time as a single 2-byte (16-bit) integer.
Scaling each sample value by a given coefficient changes the audio volume.
Example 1) Each sample value × 2.0 → 2 times the original volume
Example 2) Each sample value × 0.5 → Half the original volume

4. Japanese Era - Western Calendar Conversion

https://github.com/YukaKoshiba/MyknowledgeDocs/wiki/8.%E3%83%8F%E3%83%BC%E3%83%89%E3%82%A6%E3%82%A7%E3%82%A2%E3%83%BB%E3%83%A1%E3%83%A2%E3%83%AA%E3%83%BB%E3%83%87%E3%83%BC%E3%82%BF%E6%A7%8B%E9%80%A0#%E6%9C%A8
Era Name Years Start Year End Year Japanese Era → Western Calendar Western Calendar → Japanese Era
Reiwa 2019 2000 + (Japanese Era Year + 18) Last 2 digits of Western Year - 18
Heisei 31 1989 2019 2000 + (Japanese Era Year - 12) Last 2 digits of Western Year + 12
Showa 64 1926 1989 1900 + (Japanese Era Year + 25) Last 2 digits of Western Year - 25
Taisho 15 1912 1926 1900 + (Japanese Era Year + 11) Last 2 digits of Western Year - 11
Meiji 45 1868 1912 1900 + (Japanese Era Year - 33) Last 2 digits of Western Year + 33

Excel Functions

Preconditions
Reiwa: R, Heisei: H, Showa: S, Taisho: T, Meiji: M
(Example) Heisei 27 → H27

What to do
Convert H27 (Japanese Era) entered in cell H2 to 2015 (Western Calendar)


=SWITCH(LEFT(H2,1),"R",2000+VALUE(RIGHT(H2,LEN(H2)-1)+18),
"H",2000+VALUE(RIGHT(H2,LEN(H2)-1)-12),
"S",1900+VALUE(RIGHT(H2,LEN(H2)-1)+25),
"T",1900+VALUE(RIGHT(H2,LEN(H2)-1)+11),
"M",1900+VALUE(RIGHT(H2,LEN(H2)-1)-33))

5. Color Models

Mathematical models that define how colors are represented.
They show the combination of basic color components used to generate colors and indicate the structure of the color space.

Color Model Description Use Case Representative Colors
Additive Color Mixing A method of creating various colors by mixing RGB (red, green, blue) light.
Mixing all lights results in white.
Red, green, and blue are specified from 0 to 255.
Combining complementary colors results in gray.
Electronic devices (255,0,0): Red
(0,255,0): Green
(0,0,255): Blue
(255,255,0): Yellow
(0,255,255): Cyan
(255,0,255): Magenta
(255, 127, 0): Orange
(0, 255, 127): Chartreuse
(255,255,255): White
Subtractive Color Mixing A method of creating various colors by mixing four inks: CMYK (cyan, magenta, yellow, black), which subtract light.
Mixing all lights results in white.
Mixing all inks results in black.
Printed materials
Hexadecimal Color Model (Hex Color) Specified using hexadecimal (hexadecimal)/hex values.
Expressed as #(red)(green)(blue).
Web design
Image editing software, etc.
#00FF00: Green
HSL Color Model A color representation method composed of three elements: hue, saturation, and lightness.
Closer to how humans perceive color.
Hue: 0-360
Saturation: 0-100%
Lightness: 0-100%
Web design
Image editing software, etc.
hsl(240, 100%, 50%): Blue
RGBA Color Model rgba(redValue, greenValue, blueValue, alphaValue)
Specifies opacity (Alpha) in addition to additive color mixing (RGB).
alphaValue: Specified from 0 to 1 or 0% to 100%.
Web design, etc.

Useful website

Adobe Color

6. Computer Science (CS)

The academic discipline (field of study) that researches computers and everything related to them, with information processing as the ultimate goal.
Computer-related topics you might learn in a Computer Science degree program or bootcamp include:

Purpose: Development and improvement of computer systems concerning hardware and software

Key Elements

  • Hardware and Software Components
  • Algorithms and Data Structures
  • Artificial Intelligence
  • Network Design

= Computer Science (CS) is one of the research fields where the above key elements are interrelated.

(Supplement) Other research fields where the above key elements are interrelated:

  • Computer Engineering
    A practice combining computer science and electrical engineering with the goal of creating hardware, software, and network-related solutions.
  • Information Systems
  • A field of study dealing with the use of computer hardware, software, and networks for collecting data and processing it into information.
  • Information Technology
  • The study of managing and delivering information through computer systems.
  • Software Engineering
  • Software Engineering: The design, development, testing, and maintenance of software such as applications, web applications, and mobile applications.
    Software engineers are often specialized as backend, frontend, or full-stack engineers.

    Software Engineers

    • Backend Engineer
      Development of microservices and APIs using relevant programming languages (PHP, Python, C++, Java, NodeJS (JavaScript), etc.).
    • Frontend Engineer
      Development of user interfaces (UI) using markup languages, CSS, JavaScript, and other languages that can compile to HTML/JavaScript.
    • Full-stack Engineer
      Combines frontend and backend engineering with computer science principles to implement web and other related solutions.

    Other career paths in the field of Computer Science

    • Data Science
      Collection and analysis of data aimed at obtaining practical information that leads to data-driven solutions.
    • Artificial Intelligence Engineering
      Research on the development, testing, and maintenance of computer systems capable of performing the same activities as humans.
    • System Analysis
      Analyzing systems within a company, identifying goals and problems the company faces, and implementing viable solutions that can solve the problems.
    • Database Administration
      Management and maintenance of database management systems (DBMS) such as PostgreSQL, MySQL, Apache Cassandra, MongoDB.

    7. Information Technology (IT)

    Management of computers and information systems.

    Purpose: Solving problems by adjusting and assembling existing computer systems (HW and SW).

    Career paths in the Information Technology (IT) field

    • Business Intelligence Analysis
    • Customer Support Technician
    • Cybersecurity
    • Cloud Computing
    • Augmented Reality (AR)
    • Virtual Reality (VR)

    Reference

    Free Code Camp

    Computer Science VS Information Technology – What's the Difference Between CS and IT?

    API

    API: Application Programming Interface
    A **mechanism** for two different software/systems to communicate with each other.
    It defines a set of rules and protocols for requesting and exchanging data.

    It can be used to retrieve information from external sources, send data to external services, and perform various other actions.
    Widely used in web development to access data from various online services, such as social media platforms, weather data, and financial information.

    Common API Types

>
RESTful API Widely used for simple data retrieval and manipulation.
Uses standard HTTP methods such as GET, POST, PUT, DELETE.
Third-party APIs Many online services provide APIs that allow access to their data, such as the Twitter API for Twitter or the Google Maps API for location information.
Weather APIs APIs like OpenWeatherMap and WeatherAPI can retrieve weather information.
Financial APIs APIs like Alpha Vantage and Yahoo Finance can retrieve financial data such as stock prices.

Reference

8. File Paths

Path Description
Absolute Path Indicates the complete path from the top-level directory in the file system (usually the root directory / (Linux/macOS) or C:\ (Windows)).
Always points to the same location regardless of the current directory.
Relative Path Indicates the path relative to the current working directory.
The location it points to changes depending on the current location.
`./`: Represents the current directory itself.
`../`: Represents the parent directory (one level up).
Other `~` (tilde): Represents the user's home directory.

9. XBRL

XBRL: Extensible Business Reporting Language
An international standard for electronically describing and exchanging business information such as financial reports.
Aims to enable financial statements and other business information to be commonly understood and processed across different systems.
→ Reduces manual data entry and conversion, enabling automated processing and analysis of information.
→ Allows investors, analysts, and regulatory authorities to easily compare and analyze corporate financial information.

Structure

  • XML (Extensible Markup Language) based: Describes the structure and meaning of data.
  • Taxonomy: A dictionary (or template) defining reporting items for financial statements (names, definitions, calculation formulas).
  • Instance Document: Companies create "instance documents" that describe actual financial data based on the taxonomy.
⚠️ **GitHub.com Fallback** ⚠️